:root {
  /* Variante A · Nuit : fond anthracite, accent orange de Grapes */
  --fond: #121211;
  --fond-carte: #1d1c1a;
  --encre: #ece8e1;
  --doux: #9a948a;
  --filet: #2c2a27;
  --accent: #f29a38;
  --note: #e3c46d;
  --note-fond: #2a2516;
  --largeur: 72rem;
  color-scheme: dark;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--fond);
  color: var(--encre);
  font-family: "Inter", "Helvetica Neue", Arial, sans-serif;
  font-weight: 300;
  font-size: 1.05rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }

/* En-tête */
.entete {
  position: sticky; top: 0; z-index: 20;
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  max-width: var(--largeur); margin: 0 auto; padding: 1.4rem 1rem;
  background: var(--fond);
}
.logo {
  text-decoration: none; font-weight: 300; font-size: 1.15rem;
  letter-spacing: 0.02em; white-space: nowrap;
}
.nav { display: flex; align-items: center; gap: 1.6rem; }
.nav-liste { display: flex; gap: 1.3rem; list-style: none; margin: 0; padding: 0; }
.nav-liste > li { position: relative; }
.nav-liste a {
  text-decoration: none; font-size: 0.88rem; color: var(--encre);
  padding: 0.3rem 0; display: inline-block; white-space: nowrap;
}
.nav-liste a:hover, .nav-liste a.actif { color: var(--accent); }
.nav-liste a.actif { box-shadow: inset 0 -1px 0 var(--accent); }
.sous-menu {
  position: absolute; left: -1rem; top: 100%;
  min-width: 15rem; list-style: none; margin: 0; padding: 0.8rem 1rem;
  background: var(--fond); border: 1px solid var(--filet);
  opacity: 0; visibility: hidden; transform: translateY(4px);
  transition: opacity .15s, transform .15s, visibility .15s;
}
.nav-liste > li:hover > .sous-menu,
.nav-liste > li:focus-within > .sous-menu { opacity: 1; visibility: visible; transform: none; }
.sous-menu a { display: block; padding: 0.25rem 0; }
.sous-menu .niveau-2 a { padding-left: 0.9rem; color: var(--doux); font-size: 0.84rem; }
.langue { font-size: 0.8rem; color: var(--doux); text-decoration: none; letter-spacing: 0.06em; text-transform: uppercase; }
.langue:hover { color: var(--accent); }
.burger { display: none; }

@media (max-width: 1080px) {
  .burger {
    display: block; background: none; border: 1px solid var(--filet); color: var(--encre);
    font: inherit; font-size: 0.85rem; padding: 0.35rem 0.8rem; border-radius: 2rem; cursor: pointer;
  }
  .nav {
    display: none; position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: flex-start; gap: 1rem;
    background: var(--fond); padding: 1rem 1rem 2rem; border-bottom: 1px solid var(--filet);
    max-height: calc(100vh - 5rem); overflow-y: auto;
  }
  .nav.ouvert { display: flex; }
  .nav-liste { flex-direction: column; gap: 0.3rem; width: 100%; }
  .nav-liste > li > a { font-size: 1.05rem; }
  .sous-menu {
    position: static; opacity: 1; visibility: visible; transform: none;
    border: 0; padding: 0 0 0.4rem 1rem; min-width: 0; background: none;
  }
}

/* Bandeau brouillon */
.bandeau-brouillon {
  background: var(--note-fond); color: var(--note); text-align: center;
  font-size: 0.85rem; padding: 0.5rem 1rem;
}

/* Accueil */
.heros { position: relative; max-width: var(--largeur); margin: 0 auto; padding: 0 1rem; }
.heros img { width: 100%; aspect-ratio: 16 / 8; object-fit: cover; }
.heros-texte { padding: 2.2rem 0 0; max-width: 44rem; }
.heros-texte h1 { font-weight: 300; font-size: clamp(2.2rem, 6vw, 4rem); line-height: 1.05; margin: 0; letter-spacing: -0.01em; }
.heros-texte .metier { margin: 0.6rem 0 0; color: var(--doux); letter-spacing: 0.04em; }
.heros-texte .accroche { margin: 1.4rem 0 0; font-size: 1.2rem; }
.references { color: var(--doux); font-size: 0.95rem; margin-top: 1rem; }

.section-accueil { max-width: var(--largeur); margin: 0 auto; padding: 3.5rem 1rem 0; }
.section-accueil > h2, .bloc-titre {
  font-size: 0.8rem; font-weight: 500; letter-spacing: 0.14em; text-transform: uppercase;
  color: var(--doux); margin: 0 0 1.2rem;
}

/* Pages de rubrique : navigation à gauche */
.page {
  max-width: var(--largeur); margin: 0 auto; padding: 2.5rem 1rem 0;
  display: grid; grid-template-columns: 13rem minmax(0, 1fr); gap: 3rem;
}
.page.sans-rubrique { grid-template-columns: minmax(0, 1fr); max-width: 50rem; }
.sous-nav { list-style: none; margin: 0; padding: 0; position: sticky; top: 6rem; align-self: start; }
.sous-nav li { margin-bottom: 0.45rem; }
.sous-nav a { text-decoration: none; font-size: 1rem; color: var(--doux); }
.sous-nav a:hover { color: var(--encre); }
.sous-nav a.actif { color: var(--encre); box-shadow: inset 0 -1px 0 var(--accent); }
.sous-nav .niveau-2 { padding-left: 0.9rem; }
.sous-nav .niveau-2 a { font-size: 0.92rem; }
.sous-nav .titre-rubrique a { color: var(--encre); font-weight: 400; }
@media (max-width: 760px) {
  .page { grid-template-columns: minmax(0, 1fr); gap: 1.2rem; padding-top: 1.5rem; }
  .sous-nav { position: static; display: flex; flex-wrap: wrap; gap: 0.3rem 1rem; }
  .sous-nav li { margin: 0; }
  .sous-nav .niveau-2 { padding-left: 0; }
}

.contenu { min-width: 0; max-width: 46rem; }
.contenu h1 { font-weight: 300; font-size: clamp(2rem, 5vw, 3rem); line-height: 1.1; margin: 0; letter-spacing: -0.01em; }
.chapo { font-size: 1.2rem; color: var(--doux); margin: 0.8rem 0 2.2rem; }
.contenu p { margin: 0 0 1.1rem; }
.bloc { margin: 0 0 2.4rem; }
.bloc-titre { margin-top: 3rem; }
h2.bloc-titre-grand { font-weight: 400; font-size: 1.35rem; margin: 3rem 0 1rem; }

figure { margin: 0; }
figcaption { font-size: 0.85rem; color: var(--doux); margin-top: 0.5rem; }
figure.petite img { max-width: 20rem; }

.citation { margin: 0; padding: 0 0 0 1.4rem; border-left: 1px solid var(--accent); font-style: italic; font-size: 1.15rem; }

.faits { list-style: none; margin: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 0.5rem 1.6rem; }
.faits li { font-size: 0.85rem; letter-spacing: 0.08em; text-transform: uppercase; font-weight: 400; }

.video h3 { font-weight: 400; font-size: 1rem; margin: 0 0 0.6rem; }
.video video { width: 100%; background: #000; display: block; }

.liens { list-style: none; margin: 0; padding: 0; }
.liens li { border-top: 1px solid var(--filet); }
.liens li:last-child { border-bottom: 1px solid var(--filet); }
.liens a { display: flex; justify-content: space-between; gap: 1rem; padding: 0.7rem 0; text-decoration: none; }
.liens a::after { content: "↗"; color: var(--doux); }
.liens a:hover { color: var(--accent); }

/* Cartes */
.cartes { display: grid; grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr)); gap: 2rem 1.6rem; }
.cartes.grandes { grid-template-columns: repeat(auto-fit, minmax(19rem, 1fr)); }
.carte { text-decoration: none; display: block; }
.carte-image { aspect-ratio: 4 / 3; background: var(--fond-carte); overflow: hidden; }
.carte-image img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s; }
.carte:hover .carte-image img { transform: scale(1.03); }
.carte-image img[src*="vinia-logo"], .carte-image img[src*="grapes-logo"] { object-fit: contain; padding: 12%; }
img[src*="vinia-logo"] { background: #f4f3f0; }
figure img[src*="vinia-logo"] { padding: 1.2rem; }
.carte:hover .carte-image img[src*="vinia-logo"], .carte:hover .carte-image img[src*="grapes-logo"] { transform: none; }
/* Logo Grapes (traits noirs sur fond transparent) : en blanc sur fond sombre */
img[src*="grapes-logo"] { filter: invert(1); }
.carte h3 { font-weight: 400; font-size: 1.15rem; margin: 0.8rem 0 0.2rem; }
.carte p { margin: 0; color: var(--doux); font-size: 0.95rem; }
.carte .suite { display: inline-block; margin-top: 0.4rem; font-size: 0.85rem; color: var(--accent); }

.videos-ext { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: 1.4rem; }
.video-ext { text-decoration: none; }
.video-ext .carte-image { aspect-ratio: 16 / 9; position: relative; }
.video-ext .carte-image::after {
  content: "▶"; position: absolute; inset: 0; display: grid; place-items: center;
  color: #fff; font-size: 1.6rem; background: rgba(0,0,0,.25); opacity: 0; transition: opacity .2s;
}
.video-ext:hover .carte-image::after { opacity: 1; }
.video-ext h4 { font-weight: 400; margin: 0.6rem 0 0.1rem; font-size: 0.98rem; }
.video-ext p { margin: 0; font-size: 0.85rem; color: var(--doux); }

/* Actualités */
.actus { list-style: none; margin: 0; padding: 0; }
.actus li { display: grid; grid-template-columns: 11rem minmax(0, 1fr); gap: 1.2rem; padding: 1.2rem 0; border-top: 1px solid var(--filet); }
.actus .date { color: var(--doux); font-size: 0.9rem; }
.actus h3 { font-weight: 400; font-size: 1.1rem; margin: 0 0 0.2rem; }
.actus h3 a { text-decoration: none; }
.actus h3 a:hover { color: var(--accent); }
.actus p { margin: 0; color: var(--doux); }
@media (max-width: 600px) { .actus li { grid-template-columns: 1fr; gap: 0.2rem; } }

/* Boutique */
.produits { display: grid; grid-template-columns: repeat(auto-fill, minmax(13rem, 1fr)); gap: 2rem 1.4rem; }
.produit .carte-image { aspect-ratio: 1; }
.produit h3 { font-weight: 400; font-size: 1.05rem; margin: 0.7rem 0 0.1rem; }
.produit p { margin: 0; color: var(--doux); font-size: 0.9rem; }
.prix { font-weight: 400; margin-top: 0.3rem; }
.bouton {
  display: inline-block; margin-top: 0.6rem; padding: 0.45rem 0.9rem; border: 1px solid var(--encre);
  border-radius: 2rem; font-size: 0.85rem; text-decoration: none;
}
.bouton:hover { border-color: var(--accent); color: var(--accent); }

/* Contact, écoute */
.contact-mail { font-size: clamp(1.2rem, 3.5vw, 1.8rem); font-weight: 300; text-decoration: none; border-bottom: 1px solid var(--accent); }
.ecoute { display: flex; flex-wrap: wrap; gap: 0.6rem; }

/* Notes « à compléter », visibles seulement dans la maquette */
.a-completer {
  border: 1px dashed var(--note); background: var(--note-fond); color: var(--note);
  padding: 0.8rem 1rem; font-size: 0.9rem; border-radius: 4px;
}
.a-completer strong { font-weight: 500; letter-spacing: 0.06em; text-transform: uppercase; font-size: 0.75rem; display: block; margin-bottom: 0.2rem; }

/* Pied */
.pied {
  max-width: var(--largeur); margin: 5rem auto 0; padding: 2rem 1rem 2.5rem;
  border-top: 1px solid var(--filet);
  display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem;
  font-size: 0.85rem; color: var(--doux);
}
.pied-reseaux { display: flex; flex-wrap: wrap; gap: 1.1rem; }
.pied a { text-decoration: none; }
.pied a:hover { color: var(--accent); }

/* Galerie (On tour) */
.galerie { display: grid; grid-template-columns: repeat(auto-fill, minmax(14rem, 1fr)); gap: 1rem; margin: 2rem 0; }
.galerie img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; display: block; }
.galerie figcaption { font-size: 0.8rem; color: var(--doux); margin-top: 0.4rem; }

/* Vidéo verticale (format téléphone) */
.video.verticale { max-width: 22rem; }

/* Aperçus de partition : page entière visible, sur fond blanc */
.produit .carte-image img[src*="partition-"] { object-fit: contain; background: #fff; }

/* Crédits photo dans le pied de page */
.pied-credits { font-size: 0.75rem; color: var(--doux); margin-bottom: 0.4rem; }
.audio h3 { font-weight: 400; font-size: 1rem; margin: 0 0 0.6rem; }
.audio audio { width: 100%; max-width: 36rem; display: block; }

/* Vidéo YouTube lue dans le site (essai) */
.yt-fenetre { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,.88); display: grid; place-items: center; padding: 16px; }
.yt-cadre { width: min(100%, calc((100vh - 6rem) * 16 / 9)); aspect-ratio: 16 / 9; }
.yt-cadre iframe { width: 100%; height: 100%; border: 0; display: block; }
.yt-fermer { position: absolute; top: 0.6rem; right: 1rem; background: none; border: 0; color: #fff; font-size: 2.4rem; line-height: 1; cursor: pointer; }
.yt-fenetre { grid-template-rows: auto auto; align-content: center; gap: 0.8rem; }
.yt-plein-ecran { justify-self: end; background: none; border: 1px solid rgba(255,255,255,.5); color: #fff; font: inherit; font-size: 0.85rem; padding: 0.3rem 0.8rem; cursor: pointer; }
.yt-cadre:fullscreen { width: 100%; height: 100%; background: #000; }
.yt-cadre { position: relative; }
.yt-capteur { position: absolute; inset: 0; cursor: pointer; }
.yt-cadre.en-pause .yt-capteur::after { content: "▶"; position: absolute; inset: 0; display: grid; place-items: center; color: rgba(255,255,255,.85); font-size: 3rem; }

/* Vidéo et liste des musiciens côte à côte */
/* Le titre de la vidéo passe au-dessus ; la liste est centrée verticalement sur la vidéo elle-même */
.cote-a-cote { display: grid; grid-template-columns: minmax(0, 22rem) 1fr; grid-template-rows: auto auto; column-gap: 2.4rem; }
.cote-a-cote > div:first-child, .cote-a-cote > div:first-child > .video { display: contents; }
.cote-a-cote > div:first-child h3 { grid-column: 1; grid-row: 1; }
.cote-a-cote > div:first-child video { grid-column: 1; grid-row: 2; }
.cote-a-cote > div:last-child { grid-column: 2; grid-row: 2; align-self: center; }
@media (max-width: 700px) {
  .cote-a-cote { grid-template-columns: 1fr; }
  .cote-a-cote > div:last-child { grid-column: 1; grid-row: 3; margin-top: 1.6rem; }
}
.musiciens { list-style: none; margin: 0; padding: 0; }
.musiciens li { padding: 0.7rem 0; border-bottom: 1px solid var(--filet); display: flex; flex-direction: column; }
.musiciens li:first-child { padding-top: 0; }
.musiciens .nom { font-size: 1.1rem; }
.musiciens .instrument { color: var(--doux); font-size: 0.95rem; }

/* ===== ANIMATIONS ===== */
/* 1. Transition fluide d'une page à l'autre (fondu + léger glissement) */
@view-transition { navigation: auto; }
::view-transition-old(root) { animation: 280ms ease both sortie-page; }
::view-transition-new(root) { animation: 520ms cubic-bezier(.2,.7,.2,1) both entree-page; }
@keyframes sortie-page { to { opacity: 0; transform: translateY(-12px); } }
@keyframes entree-page { from { opacity: 0; transform: translateY(18px); } }

/* 2. Ouverture de page : titre, chapeau puis blocs apparaissent l'un après l'autre */
.contenu > * { animation: monte .8s cubic-bezier(.2,.7,.2,1) both; }
.contenu > *:nth-child(1) { animation-delay: .05s; }
.contenu > *:nth-child(2) { animation-delay: .18s; }
.contenu > *:nth-child(3) { animation-delay: .3s; }
.contenu > *:nth-child(n+4) { animation-delay: .42s; }
.sous-nav li { animation: glisse .6s ease both; }
.sous-nav li:nth-child(2) { animation-delay: .08s; } .sous-nav li:nth-child(3) { animation-delay: .14s; }
.sous-nav li:nth-child(4) { animation-delay: .2s; } .sous-nav li:nth-child(5) { animation-delay: .26s; }
@keyframes monte { from { opacity: 0; transform: translateY(24px); } }
@keyframes glisse { from { opacity: 0; transform: translateX(-14px); } }

/* 3. Vignettes : apparition au défilement, zoom lent et voile au survol */
.carte, .video-ext { opacity: 0; transform: translateY(30px); transition: opacity .9s ease, transform .9s cubic-bezier(.2,.7,.2,1); }
.carte.vu, .video-ext.vu { opacity: 1; transform: none; }
.carte-image { position: relative; }
.carte-image img { transition: transform 1.2s cubic-bezier(.2,.7,.2,1), filter .6s; }
.carte:hover .carte-image img { transform: scale(1.06); filter: brightness(.85); }
.carte h3 { transition: color .3s; }
.carte:hover h3 { color: var(--accent); }
.carte .suite { transition: letter-spacing .4s; }
.carte:hover .suite { letter-spacing: .06em; }

/* 4. En-tête qui se resserre et devient translucide au défilement */
.entete { position: sticky; top: 0; z-index: 50; transition: padding .4s, background .4s, backdrop-filter .4s; }
.entete.compacte { background: color-mix(in srgb, var(--fond) 78%, transparent); backdrop-filter: blur(10px); -webkit-backdrop-filter: blur(10px); padding-top: .5rem; padding-bottom: .5rem; }

/* 5. Vidéo à la une (page Groupes) */
.une { position: relative; height: min(78vh, 46rem); overflow: hidden; background: #000; margin-bottom: 1rem; }
.une video { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; animation: travelling 22s ease-in-out infinite alternate; }
@keyframes travelling { from { transform: scale(1.04) translateX(0); } to { transform: scale(1.14) translateX(-2%); } }
.une::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(0,0,0,.15) 0%, rgba(0,0,0,0) 40%, rgba(0,0,0,.7) 100%); }
.une-texte { position: absolute; z-index: 2; left: 0; right: 0; bottom: 0; max-width: var(--largeur); margin: 0 auto; padding: 0 16px 3.2rem; color: #fff; }
.une-texte .surtitre { font-size: .8rem; letter-spacing: .25em; text-transform: uppercase; opacity: .8; animation: monte 1s .3s both; }
.une-texte h2 { margin: .3rem 0 .4rem; font-weight: 300; font-size: clamp(2.6rem, 8vw, 5.5rem); line-height: 1; }
.une-texte h2 span { display: inline-block; animation: lettre 1.1s cubic-bezier(.2,.7,.2,1) both; }
@keyframes lettre { from { opacity: 0; transform: translateY(.6em) rotate(4deg); filter: blur(6px); } }
.une-texte p { margin: 0 0 1.4rem; max-width: 34rem; opacity: .9; animation: monte 1s 1.1s both; }
.une-bouton { display: inline-flex; gap: .6rem; align-items: center; padding: .7rem 1.3rem; border: 1px solid rgba(255,255,255,.6); color: #fff; text-decoration: none; font-size: .9rem; letter-spacing: .05em; animation: monte 1s 1.3s both; transition: background .3s, color .3s; }
.une-bouton:hover { background: #fff; color: #000; }
.une-defiler { position: absolute; z-index: 2; left: 50%; bottom: 1rem; width: 1px; height: 2.4rem; background: rgba(255,255,255,.5); overflow: hidden; }
.une-defiler::after { content: ""; position: absolute; left: 0; top: -100%; width: 1px; height: 100%; background: #fff; animation: goutte 1.8s ease-in-out infinite; }
@keyframes goutte { to { top: 100%; } }

/* Respect des visiteurs qui ont désactivé les animations */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .carte, .video-ext { opacity: 1; transform: none; }
}

/* 6. Réseaux toujours visibles : colonne fixe à droite (ordinateur) */
.reseaux-fixes { position: fixed; right: 22px; bottom: 0; z-index: 60; display: flex; flex-direction: column; align-items: center; gap: 1rem; animation: monte 1s .8s both; }
.reseaux-fixes a { width: 18px; height: 18px; display: block; background: var(--doux); -webkit-mask: var(--icone) center / contain no-repeat; mask: var(--icone) center / contain no-repeat; transition: background .25s, transform .25s; }
.reseaux-fixes a:hover { background: var(--accent); transform: translateY(-3px) scale(1.15); }
.reseaux-fixes::after { content: ""; width: 1px; height: 5rem; background: var(--filet); margin-top: .4rem; }
@media (max-width: 900px) { .reseaux-fixes { display: none; } }
