/*
 * Types de page (lancement, conférence, affiche) : mêmes blocs, trois mises en page vraiment différentes.
 * Mobile d'abord. Lisibilité : le texte posé sur une image a toujours un voile ; les couleurs d'un type clair sont fixes
 * (encre sur papier), seul l'accent suit l'événement. Mouvement : transform/opacity seulement, coupé si prefers-reduced-motion.
 * Aucune lueur, aucun dégradé sur du texte (voile d'image seulement).
 */
.fm.ty { display: block; padding-bottom: 8rem; overflow-x: clip; }
.fm.ty > * { width: auto; margin-inline: 0; }
.ty { --ty-pad: var(--fm-pad); --ty-max: var(--fm-max); --ty-gap: clamp(3.5rem, 9vw, 8rem);
  --ty-bg: #000; --ty-ink: #fff; --ty-soft: #d4d4d4; --ty-muted: #a3a3a3; --ty-card: #0f0f0f; --ty-line: rgba(255, 255, 255, .14); --ty-accent: var(--fm-red);
  background: var(--ty-bg); color: var(--ty-ink); }
.fm.ty > .ty-sec { width: min(100% - 2 * var(--ty-pad), var(--ty-max)); margin-inline: auto; padding-block: calc(var(--ty-gap) / 2); }
.ty-h2 { margin: 0 0 clamp(1.4rem, 3vw, 2.4rem); font: 800 clamp(1.9rem, 1.2rem + 3.4vw, 3.6rem)/1.04 var(--font-display); letter-spacing: -.03em; text-wrap: balance; overflow-wrap: anywhere; }
.ty p, .ty li { overflow-wrap: anywhere; }
.ty h3 { font-family: var(--font-display); }

/* ---------- Héros : image (bannière ou visuel), voile, texte ---------- */
.ty-hero { position: relative; isolation: isolate; display: grid; }
.ty-media { position: relative; overflow: hidden; background: var(--fm-card); }
.ty-media-img, .ty-media-art, .ty-media-art svg { display: block; width: 100%; height: 100%; }
.ty-media-img { object-fit: cover; }
.ty-focus-top .ty-media-img, .ty-focus-top img { object-position: 50% 0; }
.ty-focus-center .ty-media-img, .ty-focus-center img { object-position: 50% 50%; }
.ty-focus-bottom .ty-media-img, .ty-focus-bottom img { object-position: 50% 100%; }
.ty-media-art { background: var(--g-accent); }
.ty-title { margin: 0; font: 800 clamp(2.5rem, 1.4rem + 6vw, 6.5rem)/.98 var(--font-display); letter-spacing: -.04em; text-wrap: balance; overflow-wrap: anywhere; hyphens: auto; }
.ty-tagline { margin: 0; font: 600 clamp(1.15rem, 1rem + 1vw, 1.8rem)/1.25 var(--font-display); color: var(--ty-ink); text-wrap: balance; }
.ty-lead { margin: 0; max-width: 40rem; font-size: clamp(1.02rem, .98rem + .3vw, 1.2rem); line-height: 1.6; color: var(--ty-soft); }
.ty-hero-copy { display: grid; gap: 1.1rem; align-content: end; min-width: 0; }
.ty-facts { list-style: none; margin: .4rem 0 0; padding: 0; display: grid; gap: .1rem; max-width: 44rem; }
.ty-facts li { display: flex; gap: .7rem; align-items: flex-start; padding: .7rem 0; border-bottom: 1px solid var(--ty-line); min-width: 0; }
.ty-facts .icon { flex: none; margin-top: .15rem; color: var(--ty-accent); }
.ty-facts span { display: grid; gap: .15rem; min-width: 0; }
.ty-facts b { font: 700 1.02rem/1.25 var(--font-sans); }
.ty-facts small { font-size: .9rem; color: var(--ty-soft); }
.ty-ctas { display: flex; flex-wrap: wrap; gap: 1rem 1.6rem; align-items: center; margin-top: .6rem; }

/* Texte posé sur une image : voile automatique (haut léger, bas dense) = lisibilité garantie, quelle que soit l'image. */
.ty-hero-plein-ecran, .ty-hero-affiche { min-height: min(100svh, 62rem); align-items: end; color: #fff; }
.ty-hero-plein-ecran .ty-media, .ty-hero-affiche .ty-media { position: absolute; inset: 0; z-index: -1; }
.ty-hero-plein-ecran .ty-media::after, .ty-hero-affiche .ty-media::after { content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(0, 0, 0, .45) 0%, rgba(0, 0, 0, .55) 38%, rgba(0, 0, 0, .88) 100%); }
.ty-hero-plein-ecran .ty-hero-copy, .ty-hero-affiche .ty-hero-copy { padding: clamp(6rem, 22svh, 12rem) var(--ty-pad) clamp(2rem, 6vw, 4.5rem); width: min(100%, var(--ty-max)); margin-inline: auto; }
.ty-hero-plein-ecran .ty-lead, .ty-hero-plein-ecran .ty-facts small, .ty-hero-affiche .ty-lead, .ty-hero-affiche .ty-facts small { color: #e8e8e8; }
.ty-hero-plein-ecran .ty-facts li, .ty-hero-affiche .ty-facts li { border-bottom-color: rgba(255, 255, 255, .24); }
.ty-hero-plein-ecran .ty-media-art, .ty-hero-affiche .ty-media-art { opacity: .5; }
/* Parallaxe douce de l'image (variable posée par le script ; sans script, image fixe). */
.ty-hero [data-parallax] .ty-media-img, .ty-hero [data-parallax] .ty-media-art { transform: translate3d(0, var(--py, 0), 0) scale(1.08); will-change: transform; }

/* Lancement : titre centré, grand. */
.ty-hero-plein-ecran .ty-hero-copy { justify-items: center; text-align: center; }
.ty-hero-plein-ecran .ty-facts { justify-items: center; grid-template-columns: 1fr; }
.ty-hero-plein-ecran .ty-facts li { justify-content: center; text-align: left; border: 0; padding: .3rem 0; }
.ty-hero-plein-ecran .ty-ctas { justify-content: center; }
.ty-hero-plein-ecran .ty-title { font-size: clamp(2.8rem, 1.2rem + 8vw, 8.5rem); }

/* Affiche : titre géant, aligné à gauche, très serré. */
.ty-hero-affiche .ty-title { font-size: clamp(3rem, 1rem + 11vw, 11rem); line-height: .9; letter-spacing: -.05em; }
.ty-hero-affiche .ty-tagline { max-width: 34rem; }

/* Conférence : deux colonnes sur papier clair, image cadrée (le titre n'est jamais sur l'image). */
.ty-conference { --ty-bg: #f4f1ea; --ty-ink: #14110f; --ty-soft: #3d3833; --ty-muted: #5c554d; --ty-card: #fff; --ty-line: rgba(20, 17, 15, .16);
  --ty-accent: color-mix(in srgb, var(--fm-red) 62%, #000); --fm-text: #14110f; --fm-soft: #3d3833; --fm-muted: #5c554d; --fm-line: rgba(20, 17, 15, .16); }
.fm.ty > .ty-hero-split { grid-template-columns: 1fr; gap: clamp(1.5rem, 4vw, 3.5rem); width: min(100% - 2 * var(--ty-pad), var(--ty-max)); margin-inline: auto; padding-block: clamp(1.5rem, 5vw, 4rem); align-items: center; }
.ty-hero-split .ty-media { order: -1; aspect-ratio: 4 / 3; border-radius: clamp(1.2rem, 3vw, 2.4rem); }
.ty-hero-split .ty-title { font-size: clamp(2.3rem, 1.2rem + 4.6vw, 5rem); }
.ty-hero-split .ty-hero-copy { align-content: center; }
.ty-hero-split .ty-media-art { opacity: 1; }
@media (min-width: 60rem) {
  .fm.ty > .ty-hero-split { grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); min-height: min(88svh, 52rem); }
  .ty-hero-split .ty-media { order: 2; aspect-ratio: 4 / 5; max-height: 40rem; }
}
.ty-conference .fm-btn-light { background: #14110f; color: #fff; }

/* ---------- Blocs ---------- */
.ty-fig { margin: 0; overflow: hidden; border-radius: clamp(.9rem, 2vw, 1.6rem); background: var(--ty-card); }
.ty-fig img { display: block; width: 100%; height: 100%; object-fit: cover; }
.ty-fig-wide { aspect-ratio: 16 / 7; margin-bottom: clamp(1.4rem, 3vw, 2.4rem); }
.ty-fig-side { aspect-ratio: 4 / 3; }
.ty-with-fig { display: grid; gap: 1.6rem; align-items: center; }
@media (min-width: 52rem) { .ty-with-fig { grid-template-columns: 1.2fr .8fr; gap: 3.5rem; } .ty-with-fig > h2, .ty-with-fig > .ty-about-text { grid-column: 1; } .ty-with-fig > .ty-fig { grid-column: 2; grid-row: 1 / span 2; } }

.ty-about-text { display: grid; gap: 1.1rem; max-width: 46rem; }
.ty-about-text p { margin: 0; font-size: clamp(1.08rem, 1rem + .4vw, 1.3rem); line-height: 1.65; color: var(--ty-soft); white-space: pre-line; }

.ty-manifesto { display: grid; gap: 2rem; align-items: center; }
.ty-quote { margin: 0; display: grid; gap: .2rem; font: 800 clamp(1.9rem, 1rem + 4.6vw, 4.6rem)/1.05 var(--font-display); letter-spacing: -.035em; text-wrap: balance; }
.ty-quote span { color: var(--ty-muted); }
.ty-quote em { font-style: normal; color: var(--ty-accent); }
@media (min-width: 52rem) { .ty-manifesto:has(.ty-fig) { grid-template-columns: 1.3fr .7fr; } }

/* Compte à rebours */
.ty-count { text-align: center; }
.ty-count .ty-h2 { text-align: center; }
.ty-count-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(.5rem, 2vw, 1.4rem); max-width: 56rem; margin-inline: auto; }
.ty-count-cell { display: grid; gap: .3rem; padding: clamp(.9rem, 3vw, 2rem) .3rem; border: 1px solid var(--ty-line); border-radius: clamp(.8rem, 2vw, 1.6rem); background: var(--ty-card); }
.ty-count-cell b { font: 800 clamp(2rem, .8rem + 7vw, 5.6rem)/1 var(--font-display); font-variant-numeric: tabular-nums; letter-spacing: -.04em; display: block; }
.ty-count-cell small { font-size: clamp(.68rem, .6rem + .3vw, .9rem); color: var(--ty-muted); text-transform: uppercase; letter-spacing: .08em; }
.ty-count-cell:last-child b { color: var(--ty-accent); }

/* Piliers : cartes en relief (inclinaison au survol, posée par le script) */
.ty-cards { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(.8rem, 2vw, 1.4rem); grid-template-columns: 1fr; }
.ty-card { position: relative; display: grid; gap: .6rem; align-content: start; padding: clamp(1.3rem, 3vw, 2rem); border: 1px solid var(--ty-line); border-radius: clamp(1rem, 2.4vw, 1.8rem); background: var(--ty-card);
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .25s var(--fm-ease), border-color .25s; }
.ty-card:hover { border-color: var(--ty-accent); }
.ty-card h3 { margin: 0; font: 800 clamp(1.25rem, 1.1rem + .6vw, 1.6rem)/1.15 var(--font-display); letter-spacing: -.02em; }
.ty-card p { margin: 0; color: var(--ty-soft); line-height: 1.55; }
.ty-card-img { width: 100%; aspect-ratio: 16 / 10; object-fit: cover; border-radius: .9rem; }
@media (min-width: 40rem) { .ty-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64rem) { .ty-cards { grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr)); } }

/* Intervenants : cartes à portrait */
.ty-people { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(.9rem, 2vw, 1.6rem); grid-template-columns: repeat(auto-fill, minmax(min(100%, 16rem), 1fr)); }
.ty-person { display: grid; grid-template-rows: auto 1fr; overflow: hidden; border: 1px solid var(--ty-line); border-radius: clamp(1rem, 2.4vw, 1.8rem); background: var(--ty-card);
  transform: perspective(900px) rotateX(var(--rx, 0deg)) rotateY(var(--ry, 0deg)); transition: transform .25s var(--fm-ease); }
.ty-person-photo { position: relative; aspect-ratio: 4 / 5; display: grid; place-items: center; background: color-mix(in srgb, var(--ty-accent) 18%, var(--ty-card)); }
.ty-person-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%; }
.ty-initials { font: 800 clamp(3.4rem, 2rem + 5vw, 6rem)/1 var(--font-display); color: var(--ty-accent); letter-spacing: -.04em; }
.ty-person-text { display: grid; gap: .35rem; align-content: start; padding: 1.1rem 1.2rem 1.4rem; }
.ty-person h3 { margin: 0; font: 800 1.3rem/1.15 var(--font-display); letter-spacing: -.02em; }
.ty-person-role { margin: 0; font-weight: 650; color: var(--ty-accent); }
.ty-person-bio { margin: 0; color: var(--ty-soft); font-size: .95rem; line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 5; -webkit-box-orient: vertical; overflow: hidden; }
.ty-partner { margin: 1.4rem 0 0; color: var(--ty-soft); }

/* Programme en frise : ligne verticale, pastille par créneau */
.ty-timeline { list-style: none; margin: 0; padding: 0 0 0 1.6rem; position: relative; display: grid; gap: 1.2rem; }
.ty-timeline::before { content: ""; position: absolute; left: .45rem; top: .4rem; bottom: .4rem; width: 2px; background: var(--ty-line); }
.ty-day { margin-top: 1rem; font: 800 1.15rem/1.2 var(--font-display); color: var(--ty-accent); text-transform: capitalize; }
.ty-slot { position: relative; display: grid; gap: .3rem; }
.ty-slot::before { content: ""; position: absolute; left: -1.6rem; top: .45rem; width: 1rem; height: 1rem; border-radius: 50%; background: var(--ty-bg); border: 3px solid var(--ty-accent); }
.ty-slot time { font: 800 1.05rem/1.2 var(--font-display); font-variant-numeric: tabular-nums; color: var(--ty-accent); }
.ty-slot-body { display: grid; gap: .25rem; padding: 1rem 1.2rem; border: 1px solid var(--ty-line); border-radius: 1.1rem; background: var(--ty-card); }
.ty-slot-title { margin: 0; font: 700 1.15rem/1.3 var(--font-display); }
.ty-slot-sub, .ty-slot-desc { margin: 0; color: var(--ty-soft); line-height: 1.5; }
.ty-slot-room { margin: 0; display: flex; gap: .4rem; align-items: center; color: var(--ty-muted); font-size: .9rem; }
@media (min-width: 52rem) {
  .ty-timeline { padding-left: 0; max-width: 56rem; }
  .ty-timeline::before { left: 7.2rem; }
  .ty-slot { grid-template-columns: 6.2rem minmax(0, 1fr); gap: 1.6rem; align-items: start; }
  .ty-slot time { text-align: right; padding-top: .35rem; }
  .ty-slot::before { left: 6.7rem; }
  .ty-day { padding-left: 8.2rem; }
}

/* Galerie */
.ty-photos { list-style: none; margin: 0; padding: 0; display: grid; gap: .6rem; grid-template-columns: repeat(2, minmax(0, 1fr)); }
.ty-photos li { overflow: hidden; border-radius: 1rem; aspect-ratio: 1; background: var(--ty-card); }
.ty-photos li:nth-child(5n + 1) { grid-column: span 2; aspect-ratio: 16 / 9; }
.ty-photos img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .5s var(--fm-ease); }
.ty-photos li:hover img { transform: scale(1.04); }
@media (min-width: 52rem) { .ty-photos { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* Billets en comparaison */
.ty-offers { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(.8rem, 2vw, 1.4rem); grid-template-columns: 1fr; align-items: stretch; }
.ty-offer { display: grid; gap: .8rem; align-content: start; padding: clamp(1.3rem, 3vw, 2rem); border: 1px solid var(--ty-line); border-radius: clamp(1rem, 2.4vw, 1.8rem); background: var(--ty-card); }
.ty-offer-name { margin: 0; font: 700 1.1rem/1.25 var(--font-display); }
.ty-offer-price { margin: 0; font: 800 clamp(2rem, 1.4rem + 2.4vw, 3.2rem)/1 var(--font-display); letter-spacing: -.03em; color: var(--ty-accent); }
.ty-offer-desc { margin: 0; color: var(--ty-soft); line-height: 1.55; white-space: pre-line; }
.ty-offer-state { color: var(--ty-soft); font-size: .92rem; }
.ty-offer-out { opacity: .6; }
.ty-offer .fm-btn { margin-top: auto; }
@media (min-width: 40rem) { .ty-offers-2, .ty-offers-3, .ty-offers-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 64rem) { .ty-offers-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); } .ty-offers-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); } }

/* Lieu, FAQ, clôture */
.ty-venue-card { display: grid; gap: .9rem; align-content: center; }
.ty-venue-card p { margin: 0; color: var(--ty-soft); font-size: 1.1rem; }
.ty-faq-list details { border-bottom: 1px solid var(--ty-line); padding: 1.1rem 0; }
.ty-faq-list summary { cursor: pointer; font: 700 1.1rem/1.35 var(--font-display); list-style: none; display: flex; justify-content: space-between; gap: 1rem; }
.ty-faq-list summary::after { content: "+"; flex: none; font-size: 1.5rem; line-height: 1; color: var(--ty-accent); transition: transform .25s var(--fm-ease); }
.ty-faq-list details[open] summary::after { transform: rotate(45deg); }
.ty-faq-list details > p { margin: .8rem 0 0; color: var(--ty-soft); line-height: 1.65; white-space: pre-line; max-width: 46rem; }
.ty-faq-list summary:focus-visible, .ty-card:focus-visible { outline: 3px solid var(--ty-accent); outline-offset: 4px; }
.ty-closing { display: grid; justify-items: center; text-align: center; gap: 1.6rem; }
.ty-closing-title { margin: 0; font: 800 clamp(2rem, 1rem + 5vw, 5rem)/1.02 var(--font-display); letter-spacing: -.04em; text-wrap: balance; max-width: 22ch; }
.ty-org { margin-block: 0; text-align: center; color: var(--ty-muted); font-size: .9rem; }
.ty-conference .fm-btn-off { background: #d9d4cb; color: #4a443d; }

/* ---------- Différences de forme entre les types ---------- */
/* Lancement : intervenants à parcourir en glissant (cartes qui s'accrochent) sur téléphone. */
.ty-lancement .ty-people { grid-auto-flow: column; grid-auto-columns: minmax(15rem, 78%); grid-template-columns: none; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 1rem; scrollbar-width: thin; }
.ty-lancement .ty-person { scroll-snap-align: start; }
@media (min-width: 64rem) { .ty-lancement .ty-people { grid-auto-flow: row; grid-auto-columns: auto; grid-template-columns: repeat(auto-fill, minmax(16rem, 1fr)); overflow: visible; } }
/* Affiche : programme en grands chiffres, intervenants en lignes qui alternent, billets en lignes. */
.ty-slot time { white-space: nowrap; }
.ty-affiche .ty-slot time { font-size: clamp(1.6rem, 1rem + 2.4vw, 3rem); }
.ty-affiche .ty-slot-body { border: 0; border-top: 1px solid var(--ty-line); border-radius: 0; background: none; padding-inline: 0; }
.ty-affiche .ty-slot::before, .ty-affiche .ty-timeline::before { display: none; }
.ty-affiche .ty-timeline { padding-left: 0; max-width: none; }
.ty-affiche .ty-slot-title { font-size: clamp(1.3rem, 1rem + 1.4vw, 2.2rem); }
@media (min-width: 52rem) {
  .ty-affiche .ty-slot { grid-template-columns: clamp(8rem, 13vw, 12rem) minmax(0, 1fr); }
  .ty-affiche .ty-slot time { text-align: left; }
  .ty-affiche .ty-day { padding-left: 0; }
  .ty-affiche .ty-people { grid-template-columns: 1fr; }
  .ty-affiche .ty-person { grid-template-columns: minmax(0, 18rem) 1fr; grid-template-rows: none; align-items: stretch; }
  .ty-affiche .ty-person-photo { aspect-ratio: auto; min-height: 14rem; }
  .ty-affiche .ty-person-text { align-content: center; padding: 1.6rem 2rem; }
  .ty-affiche .ty-person:nth-child(even) { grid-template-columns: 1fr minmax(0, 18rem); }
  .ty-affiche .ty-person:nth-child(even) .ty-person-photo { order: 2; }
}
.ty-affiche .ty-offers { grid-template-columns: 1fr; }
.ty-affiche .ty-offer { grid-template-columns: 1fr auto; align-items: center; }
.ty-affiche .ty-offer > .fm-btn, .ty-affiche .ty-offer-desc, .ty-affiche .ty-offer-state { grid-column: 1 / -1; }
/* Conférence : cartes blanches sur papier, ombre douce. */
.ty-conference .ty-card, .ty-conference .ty-person, .ty-conference .ty-offer, .ty-conference .ty-slot-body, .ty-conference .ty-count-cell { box-shadow: 0 1px 2px rgba(20, 17, 15, .06), 0 8px 24px rgba(20, 17, 15, .06); }

/* ---------- Mouvement : entrée au chargement, glissement au défilement. Rien n'est caché sans CSS animé. ---------- */
@media (prefers-reduced-motion: no-preference) {
  .ty-hero-copy > * { animation: ty-up .9s var(--fm-ease) backwards; }
  .ty-hero-copy > *:nth-child(2) { animation-delay: .08s; } .ty-hero-copy > *:nth-child(3) { animation-delay: .16s; }
  .ty-hero-copy > *:nth-child(4) { animation-delay: .24s; } .ty-hero-copy > *:nth-child(5) { animation-delay: .32s; }
  .ty-count-cell b { animation: ty-tick .5s var(--fm-ease); }
  @keyframes ty-up { from { opacity: 0; transform: translate3d(0, 1.6rem, 0); } }
  @keyframes ty-tick { from { opacity: .3; transform: translate3d(0, -.3em, 0); } }
  @supports (animation-timeline: view()) {
    .ty-sec > h2, .ty-card, .ty-person, .ty-offer, .ty-slot, .ty-quote, .ty-photos li, .ty-closing-title { animation: ty-reveal linear both; animation-timeline: view(); animation-range: entry 0% entry 40%; }
    @keyframes ty-reveal { from { opacity: 0; transform: translate3d(0, 2rem, 0); } to { opacity: 1; transform: none; } }
  }
}
@media (prefers-reduced-motion: reduce) {
  .ty-card, .ty-person { transform: none !important; }
  .ty-hero [data-parallax] .ty-media-img, .ty-hero [data-parallax] .ty-media-art { transform: none; will-change: auto; }
}

/* ---------- Bannière dans la mise en page d'origine (sans type) ---------- */
.sc-banner { position: relative; overflow: hidden; border-radius: clamp(1rem, 2.4vw, 1.8rem); aspect-ratio: 16 / 9; max-height: 28rem; background: var(--fm-card); }
.sc-banner img { width: 100%; height: 100%; object-fit: cover; display: block; }
.sc-banner.ty-focus-top img { object-position: 50% 0; } .sc-banner.ty-focus-bottom img { object-position: 50% 100%; }
@media (max-width: 40rem) { .sc-banner { aspect-ratio: 4 / 3; } }
