/* =========================================================
   John Paillé — Portfolio v2
   DA alignée sur la bannière LinkedIn :
   fond crème + confettis pastel, encre marine, pastilles
   capitales condensées, annotations manuscrites, étoiles.
   ========================================================= */

:root {
    /* Couleurs */
    --cream: #faf6f0;
    --paper: #fffdf9;
    --navy: #2b2a6b;
    --navy-deep: #1e1d52;
    --ink: #24233a;
    --muted: #625f74;
    --line: #e9e2d8;

    --pink: #f5c9d2;
    --butter: #f7e3a3;
    --mint: #cde8db;
    --lilac: #dcd6f4;
    --peach: #f7d4bb;

    /* Typo */
    --font-body: "DM Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
    --font-label: "Oswald", "Arial Narrow", sans-serif;
    --font-hand: "Caveat", "Segoe Print", cursive;

    /* Divers */
    --radius: 18px;
    --radius-sm: 10px;
    --shadow: 0 1px 2px rgba(36, 35, 58, .04), 0 8px 24px rgba(36, 35, 58, .06);
    --shadow-hover: 0 2px 4px rgba(36, 35, 58, .05), 0 16px 40px rgba(36, 35, 58, .10);
    --ease: cubic-bezier(.2, .7, .2, 1);
    --container: 1160px;
    --header-h: 72px;
}

/* ---------- Reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html { scroll-behavior: smooth; scroll-padding-top: calc(var(--header-h) + 16px); }
body {
    font-family: var(--font-body);
    font-size: 1.0625rem;
    line-height: 1.65;
    color: var(--ink);
    background: var(--cream);
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; text-decoration: none; }
ul, ol { list-style: none; padding: 0; }
button, input, textarea { font: inherit; color: inherit; }
:focus-visible { outline: 3px solid var(--navy); outline-offset: 3px; border-radius: 6px; }

.sr-only {
    position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
    overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}
[hidden] { display: none !important; }
.skip-link {
    position: absolute; left: 16px; top: -60px; z-index: 200;
    background: var(--navy); color: #fff; padding: .6rem 1rem; border-radius: 999px;
}
.skip-link:focus { top: 12px; }

.container { width: min(100% - 32px, var(--container)); margin-inline: auto; }
@media (min-width: 640px) { .container { width: min(100% - 64px, var(--container)); } }

/* ---------- Éléments de la DA ---------- */

/* Pastille marine façon bannière */
.pill {
    display: inline-flex; align-items: center; justify-content: center; gap: .55em;
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase;
    letter-spacing: .04em; line-height: 1.1;
    background: var(--navy); color: #fff;
    padding: .7em 1.4em; border-radius: 999px;
}
.pill--sm { font-size: .8rem; padding: .55em 1.1em; }

/* Annotation manuscrite */
.hand {
    font-family: var(--font-hand); font-weight: 500;
    color: var(--navy); line-height: 1.15;
}

/* Confettis pastel (motif répété) */
.confetti { background: url("../img/deco/confetti.svg") 0 0 / 360px repeat; }

/* Étoile 4 branches en trait */
.sparkle { width: 22px; height: 22px; color: var(--navy); flex: none; }

/* Sur-titre de section */
.eyebrow {
    display: inline-flex; align-items: center; gap: .4rem;
    font-family: var(--font-hand); font-size: 1.6rem; color: var(--navy);
    line-height: 1; margin-bottom: .4rem;
}
.eyebrow .sparkle { width: 18px; height: 18px; }

.section { padding-block: clamp(4rem, 9vw, 7rem); }
.section-head { max-width: 640px; margin-bottom: clamp(2rem, 5vw, 3rem); }
.title { margin-bottom: 1.25rem; }
.section-head h2, .title {
    font-size: clamp(2rem, 4.2vw, 2.75rem); line-height: 1.1;
    letter-spacing: -.02em; font-weight: 700; color: var(--ink);
}
.section-head p { margin-top: .9rem; color: var(--muted); }

/* ---------- Boutons ---------- */
.btn {
    display: inline-flex; align-items: center; justify-content: center; gap: .6rem;
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase;
    letter-spacing: .05em; font-size: .95rem; line-height: 1;
    padding: 1rem 1.6rem; border-radius: 999px; border: 2px solid var(--navy);
    cursor: pointer; transition: background-color .2s var(--ease), color .2s var(--ease), transform .2s var(--ease);
}
.btn svg { width: 18px; height: 18px; }
.btn--primary { background: var(--navy); color: #fff; }
.btn--primary:hover { background: var(--navy-deep); border-color: var(--navy-deep); transform: translateY(-1px); }
.btn--ghost { background: transparent; color: var(--navy); }
.btn--ghost:hover { background: var(--navy); color: #fff; }
.btn--light { background: #fff; color: var(--navy); border-color: #fff; }
.btn--light:hover { background: var(--cream); border-color: var(--cream); }

/* ---------- Header ---------- */
.site-header {
    position: sticky; top: 0; z-index: 100; height: var(--header-h);
    background: rgba(250, 246, 240, .85);
    backdrop-filter: saturate(1.4) blur(12px); -webkit-backdrop-filter: saturate(1.4) blur(12px);
    border-bottom: 1px solid transparent;
    transition: border-color .2s var(--ease);
}
.site-header.is-scrolled { border-bottom-color: var(--line); }
.site-header .container { height: 100%; display: flex; align-items: center; justify-content: space-between; gap: 1.5rem; }

.brand { display: inline-flex; align-items: center; gap: .6rem; font-weight: 700; font-size: 1.1rem; letter-spacing: -.01em; }
.brand-mark {
    display: grid; place-items: center; width: 36px; height: 36px; border-radius: 50%;
    background: var(--navy); color: #fff;
    font-family: var(--font-label); font-weight: 500; font-size: .9rem; letter-spacing: .04em;
}

.nav { display: flex; align-items: center; gap: 2rem; }
.nav-list { display: flex; align-items: center; gap: 1.75rem; }
.nav-list a {
    font-weight: 500; font-size: .98rem; color: var(--ink); position: relative; padding-block: .3rem;
}
.nav-list a::after {
    content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 2px; border-radius: 2px;
    background: var(--navy); transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease);
}
.nav-list a:hover::after, .nav-list a[aria-current="true"]::after { transform: scaleX(1); }

.nav-toggle {
    display: none; width: 44px; height: 44px; border-radius: 50%;
    border: 1px solid var(--line); background: var(--paper); cursor: pointer;
    align-items: center; justify-content: center;
}
.nav-toggle span, .nav-toggle span::before, .nav-toggle span::after {
    display: block; width: 18px; height: 2px; background: var(--ink); border-radius: 2px;
    position: relative; transition: transform .25s var(--ease), background-color .2s;
}
.nav-toggle span::before, .nav-toggle span::after { content: ""; position: absolute; left: 0; }
.nav-toggle span::before { top: -6px; }
.nav-toggle span::after { top: 6px; }
.nav-toggle[aria-expanded="true"] span { background: transparent; }
.nav-toggle[aria-expanded="true"] span::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 860px) {
    .site-header { background: var(--cream); backdrop-filter: none; -webkit-backdrop-filter: none; }
    .nav-toggle { display: inline-flex; }
    .nav {
        position: fixed; inset: var(--header-h) 0 auto 0;
        flex-direction: column; align-items: stretch; gap: 1.25rem;
        padding: 1.5rem 16px 2rem; background: var(--cream);
        border-bottom: 1px solid var(--line); box-shadow: 0 20px 40px rgba(36, 35, 58, .08);
        transform: translateY(-8px); opacity: 0; visibility: hidden;
        transition: opacity .2s var(--ease), transform .2s var(--ease), visibility 0s .2s;
    }
    .nav.is-open { transform: none; opacity: 1; visibility: visible; transition-delay: 0s; }
    .nav-list { flex-direction: column; align-items: flex-start; gap: .25rem; }
    .nav-list a { display: block; font-size: 1.25rem; padding-block: .5rem; }
    .nav .btn { align-self: flex-start; }
}

/* ---------- Hero ---------- */
.hero {
    position: relative; overflow: hidden;
    padding-block: clamp(3rem, 7vw, 5.5rem) clamp(4rem, 8vw, 6rem);
}
.hero-deco { position: absolute; inset: 0; pointer-events: none; z-index: 0; }
.hero-deco .confetti { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .7; }
/* Fond WebGL « glaçage » (js/glaze.js) : apparaît en fondu une fois prêt */
.glaze { position: fixed; inset: 0; z-index: -1; width: 100vw; height: 100vh; display: block; pointer-events: none; opacity: 0; transition: opacity 1.2s ease; }
.glaze.is-ready { opacity: 1; }
/* Ondulation WebGL au survol des images (js/ripple.js) */
.project-media, .gallery a { position: relative; }
.ripple { position: absolute; inset: 0; width: 100%; height: 100%; display: block; pointer-events: none; }
/* Les bandeaux pleine largeur laissent passer le glaçage */
.has-glaze .keys, .has-glaze .about { background: color-mix(in srgb, var(--paper) 70%, transparent); }
.hero-deco .pastry { position: absolute; opacity: .55; }

.hero .container { position: relative; z-index: 1; }
.hero-grid {
    display: grid; grid-template-columns: 1.15fr .85fr; align-items: center;
    gap: clamp(2rem, 5vw, 4rem);
}

.hero-note { display: flex; align-items: flex-start; gap: .5rem; font-size: clamp(1.35rem, 2.4vw, 1.6rem); max-width: 30ch; margin-bottom: 1.25rem; }
.hero-note .sparkle { margin-top: .2rem; }

.hero h1 {
    font-size: clamp(3rem, 8vw, 5.5rem); line-height: .95; letter-spacing: -.035em;
    font-weight: 700; color: var(--ink);
}
.hero-role { margin-top: 1rem; font-size: clamp(1.1rem, 2vw, 1.3rem); font-weight: 500; color: var(--muted); }
.hero-status { margin-top: 1.75rem; display: flex; flex-direction: column; align-items: flex-start; gap: .5rem; }
.hero-status .pill { font-size: clamp(.95rem, 1.8vw, 1.15rem); }
.hero-status .pill-sub {
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .04em;
    color: var(--navy); font-size: clamp(.95rem, 1.8vw, 1.15rem); padding-left: 1.4em;
}
.hero-intro { margin-top: 1.5rem; max-width: 52ch; color: var(--muted); }
.hero-actions { margin-top: 2rem; display: flex; flex-wrap: wrap; gap: .75rem; }

.hero-visual { position: relative; display: flex; flex-direction: column; align-items: center; }
.portrait {
    width: min(100%, 360px); aspect-ratio: 1; border-radius: 50%;
    padding: 10px; background: #fff; box-shadow: var(--shadow);
}
.portrait img { width: 100%; height: auto; aspect-ratio: 1; border-radius: 50%; object-fit: cover; object-position: center; background: var(--lilac); }
.hero-visual .sparkle--a { position: absolute; top: 4%; left: 4%; width: 28px; height: 28px; }
.hero-visual .sparkle--b { position: absolute; top: 18%; right: 0; width: 18px; height: 18px; }

.hero-callout { margin-top: 1.25rem; display: grid; justify-items: center; gap: .35rem; text-align: center; }
.hero-callout .hand { font-size: 1.45rem; }
.hero-callout .arrow { width: 70px; height: 40px; color: var(--navy); margin-block: -.25rem .1rem; }
.hero-callout .pill { font-size: .95rem; text-transform: uppercase; }
.hero-callout .pill:hover { background: var(--navy-deep); }

@media (max-width: 860px) {
    .hero-grid { grid-template-columns: 1fr; }
    .hero-visual { order: -1; }
    .portrait { width: 220px; }
    .hero-callout { display: none; }
    .hero-deco .pastry { opacity: .35; }
}

/* ---------- Bandeau clés ---------- */
.keys {
    border-block: 1px solid var(--line); background: var(--paper);
}
.keys ul {
    display: grid; grid-template-columns: repeat(4, 1fr);
}
.keys li { padding: 1.5rem 1.25rem; border-left: 1px solid var(--line); }
.keys li:first-child { border-left: 0; }
.keys strong { display: block; font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; color: var(--navy); font-size: 1.05rem; }
.keys span { color: var(--muted); font-size: .95rem; }
@media (max-width: 860px) {
    .keys ul { grid-template-columns: 1fr 1fr; }
    .keys li:nth-child(3) { border-left: 0; }
    .keys li:nth-child(n+3) { border-top: 1px solid var(--line); }
}

/* ---------- Projets ---------- */
.filters { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 2rem; }
.filter {
    padding: .55rem 1.1rem; border-radius: 999px; border: 1px solid var(--line);
    background: var(--paper); font-weight: 500; font-size: .95rem; cursor: pointer;
    transition: background-color .2s var(--ease), color .2s var(--ease), border-color .2s var(--ease);
}
.filter:hover { border-color: var(--navy); }
.filter[aria-pressed="true"] { background: var(--navy); color: #fff; border-color: var(--navy); }

.projects { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; }
@media (max-width: 1000px) { .projects { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 640px) { .projects { grid-template-columns: 1fr; } }

.project {
    display: flex; flex-direction: column; background: var(--paper);
    border: 1px solid var(--line); border-radius: var(--radius); overflow: hidden;
    transition: box-shadow .25s var(--ease), transform .25s var(--ease);
}
.project:hover { box-shadow: var(--shadow-hover); transform: translateY(-3px); }
.project[hidden] { display: none; }
.project-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--lilac); }
.project-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s var(--ease); }
.project:hover .project-media img { transform: scale(1.03); }
.project-body { display: flex; flex-direction: column; gap: .75rem; padding: 1.4rem 1.4rem 1.5rem; flex: 1; }
.project-body h3 { font-size: 1.2rem; line-height: 1.3; letter-spacing: -.01em; }
.project-body h3 a::after { content: ""; position: absolute; inset: 0; }
.project { position: relative; }
.project-body p { color: var(--muted); font-size: .97rem; flex: 1; }
.project-more {
    display: inline-flex; align-items: center; gap: .4rem;
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .05em;
    font-size: .85rem; color: var(--navy);
}
.project-more svg { width: 16px; height: 16px; transition: transform .2s var(--ease); }
.project:hover .project-more svg { transform: translateX(4px); }

.tags { display: flex; flex-wrap: wrap; gap: .4rem; }
.tag {
    font-size: .78rem; font-weight: 500; padding: .25rem .65rem; border-radius: 999px;
    background: var(--cream); color: var(--ink); border: 1px solid var(--line);
}
.tag--com { background: var(--pink); border-color: transparent; }
.tag--ux { background: var(--lilac); border-color: transparent; }
.tag--av { background: var(--butter); border-color: transparent; }
.tag--web { background: var(--mint); border-color: transparent; }

/* ---------- Compétences ---------- */
.skills { display: grid; grid-template-columns: repeat(2, 1fr); gap: 1.5rem; }
@media (max-width: 760px) { .skills { grid-template-columns: 1fr; } }
.skill {
    background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius);
    padding: 1.75rem; display: flex; flex-direction: column; gap: 1rem;
}
.skill-head { display: flex; align-items: center; gap: .9rem; }
.skill-badge {
    width: 44px; height: 44px; border-radius: 12px; display: grid; place-items: center; flex: none;
    color: var(--navy);
}
.skill-badge svg { width: 22px; height: 22px; }
.skill-badge--com { background: var(--pink); }
.skill-badge--ux { background: var(--lilac); }
.skill-badge--av { background: var(--butter); }
.skill-badge--web { background: var(--mint); }
.skill h3 { font-size: 1.15rem; line-height: 1.3; }
.skill ul { display: grid; gap: .45rem; }
.skill li { position: relative; padding-left: 1.2rem; color: var(--muted); font-size: .98rem; }
.skill li::before {
    content: ""; position: absolute; left: 0; top: .65em; width: 6px; height: 6px; border-radius: 50%; background: var(--navy);
}
.skill-tools { margin-top: auto; padding-top: 1rem; border-top: 1px dashed var(--line); }
.skill-tools .label { display: block; font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .05em; font-size: .78rem; color: var(--muted); margin-bottom: .5rem; }

.soft {
    margin-top: 1.5rem; display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1rem;
    padding: 1.25rem 1.5rem; border-radius: var(--radius); background: var(--paper); border: 1px dashed var(--line);
}
.soft .hand { font-size: 1.4rem; margin-right: .25rem; }
.soft span:not(.hand) { color: var(--muted); }
.soft span:not(.hand):not(:last-child)::after { content: "·"; margin-left: 1rem; color: var(--line); }

/* ---------- Parcours ---------- */
.timeline { position: relative; display: grid; gap: 1rem; }
.timeline::before {
    content: ""; position: absolute; left: 9px; top: 12px; bottom: 12px; width: 2px;
    background: repeating-linear-gradient(to bottom, var(--navy) 0 6px, transparent 6px 12px); opacity: .35;
}
.step { position: relative; padding-left: 2.5rem; }
.step::before {
    content: ""; position: absolute; left: 0; top: 1.6rem; width: 20px; height: 20px; border-radius: 50%;
    background: var(--cream); border: 2px solid var(--navy);
}
.step.is-current::before { background: var(--navy); box-shadow: 0 0 0 5px var(--lilac); }
.step-card {
    display: grid; grid-template-columns: 170px 1fr; gap: 1.5rem;
    background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.4rem 1.6rem;
}
.step-date { font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; color: var(--navy); }
.step h3 { font-size: 1.12rem; line-height: 1.35; }
.step .where { color: var(--muted); font-size: .95rem; }
.step p { margin-top: .5rem; color: var(--muted); font-size: .96rem; }
@media (max-width: 640px) { .step-card { grid-template-columns: 1fr; gap: .25rem; } }

/* ---------- À propos ---------- */
.about { background: var(--paper); border-block: 1px solid var(--line); }
.about-grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(2rem, 5vw, 4.5rem); align-items: center; }
@media (max-width: 860px) { .about-grid { grid-template-columns: 1fr; } }
.about-photo { position: relative; max-width: 400px; justify-self: center; width: 100%; }
.about-photo img { border-radius: var(--radius); width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
.about-photo figcaption { position: absolute; left: -8px; bottom: -18px; transform: rotate(-3deg); background: var(--butter); padding: .35rem 1rem; border-radius: 8px; font-size: 1.35rem; }
.about-text p { color: var(--muted); }
.about-text p + p { margin-top: 1rem; }
.about-text strong { color: var(--ink); font-weight: 600; }
.method { margin-top: 1.75rem; display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; }
.method li { background: var(--cream); border-radius: var(--radius-sm); padding: 1rem; }
.method b { display: block; font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .04em; color: var(--navy); font-size: .95rem; }
.method span { font-size: .9rem; color: var(--muted); }
@media (max-width: 520px) { .method { grid-template-columns: 1fr; } }
.also { margin-top: 1.5rem; font-size: .95rem; color: var(--muted); }
/* ---------- Bandeau vers l'atelier WebGL (accueil) ---------- */
.atelier-band { padding-bottom: clamp(4rem, 9vw, 7rem); }
.atelier-band-card {
    position: relative; overflow: hidden; display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: center;
    gap: clamp(1.5rem, 4vw, 3rem); padding: clamp(1.75rem, 5vw, 3rem); border-radius: calc(var(--radius) + 8px);
    background: var(--navy); color: rgba(255, 255, 255, .85);
    transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.atelier-band-card:hover { transform: translateY(-3px); box-shadow: 0 24px 50px rgba(30, 29, 82, .3); }
.atelier-band-card .confetti { position: absolute; inset: 0; opacity: .16; pointer-events: none; }
.atelier-band-text, .atelier-band-visual { position: relative; }
.atelier-band-text .hand { color: var(--butter); font-size: 1.6rem; }
.atelier-band-text h2 { margin: .3rem 0 .8rem; color: #fff; font-size: clamp(1.7rem, 3.6vw, 2.5rem); line-height: 1.1; letter-spacing: -.02em; }
.atelier-band-text p:not(.hand) { max-width: 52ch; }
.atelier-band-text .btn { margin-top: 1.5rem; }
.atelier-band-card:hover .btn svg { transform: translateX(4px); }
.atelier-band-visual { display: grid; justify-items: center; }
.atelier-band-visual img { width: clamp(180px, 24vw, 260px); height: auto; filter: drop-shadow(0 18px 28px rgba(0, 0, 0, .25)); transition: transform .6s var(--ease); }
.atelier-band-card:hover .atelier-band-visual img { transform: rotate(-12deg) scale(1.04); }
.atelier-band-visual .pill { margin-top: -1.2rem; background: #fff; color: var(--navy); transform: rotate(-3deg); }
@media (max-width: 760px) {
    .atelier-band-card { grid-template-columns: 1fr; }
    .atelier-band-visual { order: -1; }
}
@media (prefers-reduced-motion: no-preference) {
    .atelier-band-visual img { animation: cake-turn 40s linear infinite; }
    .atelier-band-card:hover .atelier-band-visual img { animation-play-state: paused; }
}
@keyframes cake-turn { to { rotate: 360deg; } }

/* Lien « L'atelier » du menu : petite étoile pour le signaler */
.nav-atelier { display: inline-flex; align-items: center; gap: .35rem; }
.nav-atelier::before {
    content: ""; width: 12px; height: 12px; flex: none; background: var(--navy);
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2c.6 5.4 4.6 9.4 10 10-5.4.6-9.4 4.6-10 10-.6-5.4-4.6-9.4-10-10 5.4-.6 9.4-4.6 10-10z'/%3E%3C/svg%3E") center / contain no-repeat;
            mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24'%3E%3Cpath d='M12 2c.6 5.4 4.6 9.4 10 10-5.4.6-9.4 4.6-10 10-.6-5.4-4.6-9.4-10-10 5.4-.6 9.4-4.6 10-10z'/%3E%3C/svg%3E") center / contain no-repeat;
}
.nav-list a[aria-current="page"]::after { transform: scaleX(1); }

/* ---------- Contact ---------- */
.contact { position: relative; overflow: hidden; background: var(--navy); color: #fff; }
.contact .confetti { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .18; pointer-events: none; }
.contact .container { position: relative; }
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; } }
.contact .eyebrow, .contact .hand, .contact .sparkle { color: #fff; }
.contact h2 { font-size: clamp(2rem, 4.2vw, 2.75rem); line-height: 1.1; letter-spacing: -.02em; }
.contact-lead { margin-top: 1rem; color: rgba(255, 255, 255, .78); max-width: 46ch; }
.contact-list { margin-top: 2rem; display: grid; gap: .75rem; }
.contact-list a, .contact-list div {
    display: flex; align-items: center; gap: .9rem; padding: .9rem 1.1rem;
    border-radius: 14px; background: rgba(255, 255, 255, .07); border: 1px solid rgba(255, 255, 255, .12);
    transition: background-color .2s var(--ease);
}
.contact-list a:hover { background: rgba(255, 255, 255, .14); }
.contact-list svg { width: 20px; height: 20px; flex: none; opacity: .9; }
.contact-list small { display: block; font-size: .78rem; opacity: .65; text-transform: uppercase; letter-spacing: .06em; }

.form {
    background: var(--paper); color: var(--ink); border-radius: var(--radius); padding: clamp(1.4rem, 3vw, 2rem);
    display: grid; grid-template-columns: 1fr 1fr; gap: 1rem;
}
.form .full { grid-column: 1 / -1; }
@media (max-width: 520px) { .form { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 500; font-size: .92rem; margin-bottom: .35rem; }
.field input, .field textarea {
    width: 100%; padding: .85rem 1rem; border-radius: 12px; border: 1px solid var(--line); background: #fff;
    transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.field textarea { resize: vertical; min-height: 140px; }
.field input:focus, .field textarea:focus { outline: none; border-color: var(--navy); box-shadow: 0 0 0 4px var(--lilac); }
.form .btn { justify-self: start; }
.form-status { font-size: .95rem; min-height: 1.5em; align-self: center; }
.form-status.is-ok { color: #1f7a4d; }
.form-status.is-error { color: #b42318; }
.hp { position: absolute; left: -9999px; }

/* ---------- Footer ---------- */
.site-footer { padding-block: 2rem; font-size: .92rem; color: var(--muted); }
.site-footer .container { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; }
.site-footer nav ul { display: flex; flex-wrap: wrap; gap: 1.25rem; }
.site-footer a:hover { color: var(--navy); }

/* ---------- Curseur personnalisé (souris uniquement) ---------- */
.cursor-dot, .cursor-ring {
    position: fixed; top: 0; left: 0; z-index: 1000; pointer-events: none;
    border-radius: 50%; opacity: 0;
    transition: opacity .2s var(--ease);
}
.cursor-dot { width: 8px; height: 8px; margin: -4px 0 0 -4px; background: var(--navy); }
.cursor-ring {
    width: 36px; height: 36px; margin: -18px 0 0 -18px;
    border: 1.5px solid rgba(43, 42, 107, .45);
    display: grid; place-items: center;
}
.cursor-ring::before {
    content: ""; position: absolute; inset: -1.5px; border-radius: 50%;
    background: var(--lilac); opacity: 0; transform: scale(.6);
    transition: opacity .25s var(--ease), transform .25s var(--ease);
}
.cursor-ring svg { position: relative; width: 14px; height: 14px; color: var(--navy); opacity: 0; transform: scale(.4) rotate(-45deg); transition: opacity .25s var(--ease), transform .3s var(--ease); }
.cursor-label {
    position: relative; font-family: var(--font-label); font-weight: 500; text-transform: uppercase;
    letter-spacing: .06em; font-size: .7rem; color: #fff; opacity: 0; transition: opacity .2s var(--ease);
}
.cursor-ring > * { grid-area: 1 / 1; }
.cursor-ring { transition: opacity .2s var(--ease), width .25s var(--ease), height .25s var(--ease), margin .25s var(--ease), border-color .25s var(--ease); }

.has-cursor .cursor-dot, .has-cursor .cursor-ring { opacity: 1; }

/* Survol d'un lien ou bouton : pastille lilas + étoile */
.cursor--link .cursor-ring { width: 52px; height: 52px; margin: -26px 0 0 -26px; border-color: var(--navy); }
.cursor--link .cursor-ring::before { opacity: .35; transform: scale(1); }
.cursor--link .cursor-ring svg { opacity: 1; transform: none; }
.cursor--link .cursor-dot { opacity: 0; }

/* Survol d'une carte projet : pastille marine « Voir » */
.cursor--label .cursor-ring { width: 72px; height: 72px; margin: -36px 0 0 -36px; border-color: var(--navy); }
.cursor--label .cursor-ring::before { background: var(--navy); opacity: 1; transform: scale(1); }
.cursor--label .cursor-label { opacity: 1; }
.cursor--label .cursor-ring svg, .cursor--label .cursor-dot { opacity: 0; }

/* Clic */
.cursor--down .cursor-ring { width: 26px; height: 26px; margin: -13px 0 0 -13px; }

/* Sur fond marine */
.cursor--inverse .cursor-dot { background: #fff; }
.cursor--inverse .cursor-ring { border-color: rgba(255, 255, 255, .55); }
.cursor--inverse.cursor--link .cursor-ring { border-color: #fff; }
.cursor--inverse.cursor--link .cursor-ring::before { background: #fff; opacity: .2; }
.cursor--inverse.cursor--link .cursor-ring svg { color: #fff; }

/* Champs texte : curseur natif, curseur custom masqué */
.cursor--text .cursor-dot, .cursor--text .cursor-ring { opacity: 0; }

@media (hover: hover) and (pointer: fine) {
    html.custom-cursor, html.custom-cursor a, html.custom-cursor button, html.custom-cursor label { cursor: none; }
    html.custom-cursor input, html.custom-cursor textarea { cursor: text; }
}

/* =========================================================
   Animations
   ========================================================= */

/* ---------- Barre de progression de lecture ---------- */
.progress {
    position: fixed; top: 0; left: 0; right: 0; height: 3px; z-index: 150;
    background: linear-gradient(90deg, var(--navy), #6f6bc9);
    transform-origin: left; transform: scaleX(var(--p, 0)); pointer-events: none;
}

/* ---------- Entrée du hero (au chargement) ---------- */
@keyframes rise { from { opacity: 0; transform: translateY(22px); } to { opacity: 1; transform: none; } }
@keyframes pop { from { opacity: 0; transform: scale(.85); } to { opacity: 1; transform: none; } }
@keyframes write { from { clip-path: inset(0 100% 0 0); } to { clip-path: inset(0 0 0 0); } }
@keyframes draw { to { stroke-dashoffset: 0; } }

/* fill "backwards" : l'état final n'est pas figé, les effets de survol restent possibles */
[data-anim] { animation: rise .9s var(--ease) backwards; animation-delay: calc(var(--d, 0) * 110ms + 100ms); }
[data-anim="pop"] { animation-name: pop; animation-duration: 1s; }
[data-anim="write"] { animation: write 1.4s cubic-bezier(.5, 0, .3, 1) backwards; animation-delay: calc(var(--d, 0) * 110ms + 100ms); }

.hero-callout .arrow path { stroke-dasharray: 1; stroke-dashoffset: 1; animation: draw .9s var(--ease) forwards 1.5s; }
.hero-callout .arrow path + path { animation-delay: 2.2s; animation-duration: .35s; }

/* ---------- Petites vies permanentes (discrètes) ---------- */
@keyframes twinkle {
    0%, 100% { transform: scale(1) rotate(0); opacity: 1; }
    50% { transform: scale(.72) rotate(25deg); opacity: .55; }
}
@keyframes float {
    0%, 100% { translate: 0 0; }
    50% { translate: 0 -10px; }
}
@keyframes drift { to { background-position: 360px 360px; } }
@keyframes pulse {
    0% { box-shadow: 0 0 0 0 rgba(155, 222, 189, .7); }
    80%, 100% { box-shadow: 0 0 0 9px rgba(155, 222, 189, 0); }
}

.hero-visual .sparkle, .hero-note .sparkle, .eyebrow .sparkle { animation: twinkle 3.6s ease-in-out infinite; }
.hero-visual .sparkle--b { animation-delay: -1.2s; animation-duration: 4.4s; }
.eyebrow .sparkle { animation-duration: 4.8s; }

.hero-deco .pastry {
    transform: translate(var(--px, 0), var(--py, 0)) rotate(var(--r, 0deg));
    transition: transform .8s cubic-bezier(.2, .7, .2, 1);
    animation: float 7s ease-in-out infinite;
}
.hero-deco .pastry:nth-child(3) { animation-duration: 8.5s; animation-delay: -2s; }
.hero-deco .pastry:nth-child(4) { animation-duration: 6.5s; animation-delay: -4s; }
.hero-deco .pastry:nth-child(5) { animation-duration: 9s; animation-delay: -1s; }

.confetti { animation: drift 90s linear infinite; }

/* Pastille « en recherche » avec point vivant */
.live-dot {
    width: 8px; height: 8px; border-radius: 50%; background: #9bdebd; flex: none;
    animation: pulse 2.2s ease-out infinite;
}

/* ---------- Micro-interactions ---------- */
.btn svg { transition: transform .25s var(--ease); }
.btn:hover svg:has(use[href="#i-arrow"]) { transform: translateX(4px); }
.btn:hover svg:has(use[href="#i-download"]) { transform: translateY(2px); }
.btn { will-change: transform; }

.portrait { transition: transform .5s var(--ease), box-shadow .5s var(--ease); }
.portrait:hover { transform: rotate(-2deg) scale(1.015); box-shadow: var(--shadow-hover); }

.skill { transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease); }
.skill:hover { transform: translateY(-3px); box-shadow: var(--shadow-hover); border-color: transparent; }
.skill-badge { transition: transform .35s cubic-bezier(.34, 1.56, .64, 1); }
.skill:hover .skill-badge { transform: rotate(-8deg) scale(1.08); }

.step-card { transition: transform .3s var(--ease), box-shadow .3s var(--ease); }
.step:hover .step-card { transform: translateX(4px); box-shadow: var(--shadow); }

.method li { transition: transform .3s var(--ease), background-color .3s var(--ease); }
.method li:hover { transform: translateY(-3px); background: var(--lilac); }

.contact-list a svg { transition: transform .3s cubic-bezier(.34, 1.56, .64, 1); }
.contact-list a:hover svg { transform: scale(1.15) rotate(-6deg); }

.tag { transition: transform .2s var(--ease); }
.project:hover .tag { transform: translateY(-1px); }

/* ---------- Apparitions au scroll (amélioration progressive) ---------- */
.js .reveal {
    opacity: 0; transform: translateY(24px);
    transition: opacity .7s var(--ease), transform .7s var(--ease);
    transition-delay: calc(var(--i, 0) * 90ms);
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* Image des cartes projet : dévoilement par le bas */
.js .project.reveal .project-media img {
    clip-path: inset(100% 0 0 0); transform: scale(1.12);
    transition: clip-path .9s cubic-bezier(.65, 0, .35, 1), transform 1.2s var(--ease);
    transition-delay: calc(var(--i, 0) * 90ms + 150ms);
}
.js .project.reveal.is-visible .project-media img { clip-path: inset(0 0 0 0); transform: none; }

/* Sur-titres : l'écriture manuscrite se dessine */
.js .reveal .eyebrow, .js .eyebrow.reveal { clip-path: inset(0 100% 0 0); transition: clip-path 1s cubic-bezier(.5, 0, .3, 1) .15s; }
.js .reveal.is-visible .eyebrow, .js .eyebrow.reveal.is-visible { clip-path: inset(0 0 0 0); }

/* Parcours : la ligne se trace au scroll, les points apparaissent */
.timeline::before { transform-origin: top; transform: scaleY(var(--line, 1)); }
.js .timeline { --line: 0; }
.js .step.reveal::before { transform: scale(0); transition: transform .5s cubic-bezier(.34, 1.56, .64, 1) .2s; }
.js .step.reveal.is-visible::before { transform: none; }

/* Photo pâtisserie : l'étiquette se pose */
.js .about-photo.reveal figcaption { opacity: 0; transform: rotate(-12deg) translateY(10px); transition: opacity .5s var(--ease) .5s, transform .6s cubic-bezier(.34, 1.56, .64, 1) .5s; }
.js .about-photo.reveal.is-visible figcaption { opacity: 1; transform: rotate(-3deg); }

/* ---------- Mouvement réduit : tout est statique ---------- */
@media (prefers-reduced-motion: reduce) {
    html { scroll-behavior: auto; }
    *, *::before, *::after { animation: none !important; transition-duration: .01ms !important; transition-delay: 0s !important; }
    .js .reveal, .js .project.reveal .project-media img, .js .reveal .eyebrow, .js .eyebrow.reveal { opacity: 1; transform: none; clip-path: none; }
    .js .timeline { --line: 1; }
    .hero-callout .arrow path { stroke-dashoffset: 0; }
}

/* =========================================================
   Page projet
   ========================================================= */
.back {
    display: inline-flex; align-items: center; gap: .4rem; color: var(--muted); font-weight: 500; font-size: .95rem;
}
.back svg { width: 16px; height: 16px; transform: rotate(180deg); }
.back:hover { color: var(--navy); }

.case-hero { position: relative; overflow: hidden; padding-block: 2.5rem 3rem; }
.case-hero .container { position: relative; }
.case-hero .confetti { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .6; pointer-events: none; }
.case-hero .eyebrow { display: flex; margin-top: 2rem; }
.case-hero h1 { font-size: clamp(2.2rem, 5.5vw, 3.75rem); line-height: 1.05; letter-spacing: -.03em; max-width: 20ch; }
.case-hero .tags { margin-top: 1.25rem; }
.case-cover { margin-top: 2.5rem; border-radius: var(--radius); overflow: hidden; border: 1px solid var(--line); background: var(--paper); box-shadow: var(--shadow); }
.case-cover img { width: 100%; max-height: 520px; object-fit: cover; object-position: top center; }

.case-layout { display: grid; grid-template-columns: 1fr 340px; gap: clamp(2rem, 5vw, 4rem); align-items: start; }
@media (max-width: 960px) { .case-layout { grid-template-columns: 1fr; } }
.case-main > section + section { margin-top: 3rem; }
.case-main h2, .case-aside h2 {
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .05em;
    font-size: 1rem; color: var(--navy); margin-bottom: 1rem;
}
.case-lead { font-size: 1.15rem; line-height: 1.7; color: var(--ink); }
.list-check { display: grid; gap: .7rem; }
.list-check li { position: relative; padding-left: 1.9rem; color: var(--muted); }
.list-check li::before {
    content: ""; position: absolute; left: 0; top: .2em; width: 1.2rem; height: 1.2rem; border-radius: 50%;
    background: var(--lilac) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%232b2a6b' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12.5l4.5 4.5L19 7.5'/%3E%3C/svg%3E") center / 70% no-repeat;
}
.list-steps { counter-reset: s; display: grid; gap: .8rem; }
.list-steps li { counter-increment: s; position: relative; padding-left: 2.6rem; color: var(--muted); }
.list-steps li::before {
    content: counter(s, decimal-leading-zero); position: absolute; left: 0; top: 0;
    font-family: var(--font-label); font-weight: 500; color: var(--navy); font-size: 1rem;
}

.case-aside { position: sticky; top: calc(var(--header-h) + 24px); display: grid; gap: 1rem; }
@media (max-width: 960px) { .case-aside { position: static; } }
.panel { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 1.5rem; }
.panel .btn { width: 100%; }
.panel .list-check li { font-size: .95rem; }

/* ---------- Fiche recette ---------- */
.case-kicker { display: inline-block; font-size: 1.35rem; color: var(--muted); transform: rotate(-2deg); transform-origin: left; margin-bottom: .1rem; }
.case-main .case-kicker + h2, .case-aside .case-kicker + h2 { margin-bottom: 1rem; }

.recipe-meta {
    position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, 1fr);
    width: min(100% - 2rem, 920px); margin: -2.75rem auto 0;
    background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow);
}
.recipe-meta[hidden] { display: none; }
.recipe-meta > div { padding: 1.1rem 1.4rem; }
.recipe-meta > div + div { border-left: 1px dashed var(--line); }
.recipe-meta dt {
    display: flex; align-items: center; gap: .45rem;
    font-family: var(--font-label); font-weight: 500; text-transform: uppercase; letter-spacing: .05em; font-size: .78rem; color: var(--muted);
}
.recipe-meta dt svg { width: 17px; height: 17px; color: var(--navy); fill: none; flex: none; }
.recipe-meta dd { margin: .35rem 0 0; font-weight: 600; font-size: 1.05rem; color: var(--ink); display: flex; align-items: center; flex-wrap: wrap; gap: .5rem; }
@media (max-width: 720px) {
    .recipe-meta { grid-template-columns: 1fr 1fr; margin-top: -1.75rem; }
    .recipe-meta > div:nth-child(3) { border-left: 0; }
    .recipe-meta > div:nth-child(n+3) { border-top: 1px dashed var(--line); }
}

.toques { display: inline-flex; gap: .1rem; }
.toques svg { width: 22px; height: 22px; fill: transparent; color: #d3cbbf; }
.toques svg.is-on { fill: var(--butter); color: var(--navy); }
.toques-label { font-size: .85rem; font-weight: 500; color: var(--muted); }

.recipe-steps { counter-reset: s; display: grid; }
.recipe-steps li { counter-increment: s; position: relative; padding: .35rem 0 1.5rem 3.4rem; color: var(--muted); }
.recipe-steps li::before {
    content: counter(s); position: absolute; left: 0; top: 0; width: 2.3rem; height: 2.3rem; border-radius: 50%;
    display: grid; place-items: center; background: var(--navy); color: #fff;
    font-family: var(--font-label); font-weight: 500; font-size: 1rem;
}
.recipe-steps li::after { content: ""; position: absolute; left: calc(1.15rem - 1px); top: 2.6rem; bottom: .3rem; border-left: 2px dashed var(--line); }
.recipe-steps li:last-child { padding-bottom: 0; }
.recipe-steps li:last-child::after { display: none; }

.recipe-result {
    position: relative; padding: clamp(1.5rem, 4vw, 2rem); border-radius: var(--radius);
    background: color-mix(in srgb, var(--butter) 38%, var(--paper)); border: 1px solid color-mix(in srgb, var(--butter) 80%, var(--line));
}
.recipe-result #case-result { font-size: 1.1rem; line-height: 1.65; color: var(--ink); margin-bottom: 1.25rem; }
.recipe-result .list-check li::before { background-color: var(--paper); }

.recipe-card {
    position: relative; padding: 1.75rem 1.5rem 1.5rem; border-radius: var(--radius); border: 1px solid var(--line);
    background: var(--paper);
}
.recipe-card::before { /* petit ruban adhésif */
    content: ""; position: absolute; top: -10px; left: 50%; width: 84px; height: 22px; translate: -50% 0; rotate: -3deg;
    background: color-mix(in srgb, var(--pink) 75%, transparent); border-radius: 3px;
}
.ingredients li {
    display: flex; align-items: center; gap: .7rem; padding: .55rem 0; border-bottom: 1px dashed var(--line); color: var(--ink); font-size: .95rem;
}
.ingredients li:last-child { border-bottom: 0; }
.ingredients li::before { content: ""; width: 8px; height: 8px; border-radius: 50%; background: var(--mint); box-shadow: 0 0 0 3px color-mix(in srgb, var(--mint) 40%, transparent); flex: none; }
.ingredients li:nth-child(4n+2)::before { background: var(--pink); box-shadow: 0 0 0 3px color-mix(in srgb, var(--pink) 40%, transparent); }
.ingredients li:nth-child(4n+3)::before { background: var(--butter); box-shadow: 0 0 0 3px color-mix(in srgb, var(--butter) 45%, transparent); }
.ingredients li:nth-child(4n)::before { background: var(--lilac); box-shadow: 0 0 0 3px color-mix(in srgb, var(--lilac) 45%, transparent); }

.gallery { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; }
.gallery a { display: block; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--line); background: var(--paper); }
.gallery img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s var(--ease); }
.gallery a:hover img { transform: scale(1.02); }

.case-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 4rem; }
.case-nav a {
    display: block; padding: 1.25rem 1.5rem; border-radius: var(--radius); background: var(--paper); border: 1px solid var(--line);
    transition: border-color .2s var(--ease), box-shadow .2s var(--ease);
}
.case-nav a:hover { border-color: var(--navy); box-shadow: var(--shadow); }
.case-nav small { display: block; font-family: var(--font-label); text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-size: .8rem; }
.case-nav strong { font-size: 1.05rem; }
.case-nav .next { text-align: right; grid-column: 2; }
@media (max-width: 640px) { .case-nav { grid-template-columns: 1fr; } .case-nav .next { grid-column: auto; } }

.cta-band { margin-top: 4rem; }
.cta-band .inner {
    position: relative; overflow: hidden; border-radius: calc(var(--radius) + 6px); background: var(--navy); color: #fff;
    padding: clamp(2rem, 5vw, 3rem); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1.5rem;
}
.cta-band .confetti { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .18; pointer-events: none; }
.cta-band .hand { color: #fff; font-size: 1.6rem; }
.cta-band h2 { font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -.02em; }
.cta-band > .inner > * { position: relative; }
