/* ==========================================================================
   L'Instant Présent · direction « La nappe »
   Le lin blanc de la table à la française, le rubis du vin pour seul accent,
   la nuit lie de vin de la cave. Polices : IM Fell French Canon (fontes
   gravées anciennes, l'esprit des étiquettes et des cartes imprimées) et
   Hanken Grotesk pour les informations.
   ========================================================================== */
:root {
  --lin: #f6efe2;
  --papier: #fcf8f0;
  --encre: #241016;
  --encre-douce: #57434a;
  --vin: #7a1230;
  --vin-sombre: #5e0d24;
  --nuit: #1c0710;
  --nuit-surface: #290b18;
  --creme: #f6efe2;
  --creme-douce: #dccfc6;
  --rose: #eda2ae;

  --fond: var(--lin);
  --surface: var(--papier);
  --texte: var(--encre);
  --texte-doux: var(--encre-douce);
  --accent: var(--vin);
  --accent-texte: #fcf8f0;
  --titre: "IM Fell French Canon", Georgia, serif;
  --corps: "Hanken Grotesk", system-ui, sans-serif;
  --t-corps: clamp(1rem, .97rem + .15vw, 1.0625rem);
  --marge: clamp(1.25rem, 4vw, 3.5rem);

  --nav-hauteur: 60px;
  --nav-fond: var(--papier);
  --nav-texte: var(--encre);
  --nav-bord: rgb(36 16 22 / .14);
  --nav-actif: rgb(122 18 48 / .09);
  --carte-filet: rgb(36 16 22 / .14);

  --filigrane-fond: var(--papier);
  --filigrane-texte: var(--encre);
  --filigrane-bord: rgb(36 16 22 / .24);
  --filigrane-point: var(--vin);
  --assistant-fond: var(--vin);
  --assistant-texte: var(--papier);
  --assistant-panneau: var(--papier);
  --assistant-panneau-texte: var(--encre);
  --assistant-bord: rgb(36 16 22 / .16);
  --assistant-bulle: #f0e6d8;
}

h1, h2, h3 { font-family: var(--titre); font-weight: 400; line-height: 1.02; margin: 0; text-wrap: balance; }
p { margin: 0 0 1em; }
a, button { cursor: pointer; }
.rond-source { position: absolute; width: 0; height: 0; overflow: hidden; }

.surtitre { font: 700 .74rem/1.2 var(--corps); letter-spacing: .2em; text-transform: uppercase; color: var(--vin); margin: 0 0 1rem; }
.bouton {
  display: inline-flex; align-items: center; justify-content: center; gap: .6rem; min-height: 52px; padding: 0 1.6rem;
  border-radius: .2rem; background: var(--vin); color: var(--accent-texte); text-decoration: none; font-weight: 700;
  transition: background-color .2s ease, transform .2s ease;
}
.bouton svg { width: 1.15rem; height: 1.15rem; flex: none; }
.bouton:hover { background: var(--vin-sombre); }
.bouton--creux { background: transparent; color: var(--vin); box-shadow: inset 0 0 0 1.5px var(--vin); }
.bouton--creux:hover { background: rgb(122 18 48 / .08); }
.lien-fleche { display: inline-flex; align-items: center; min-height: 48px; text-decoration: none; font-weight: 700; border-bottom: 1.5px solid currentColor; }

/* Le rond de verre : la trace d'un pied de verre, sur le papier et dans le pied de page. */
.rond { display: block; color: var(--vin); fill: currentColor; }

/* Barre de navigation : lignes fines plutôt que pastilles, comme une carte imprimée. */
.navigation__nom { font-style: italic; font-size: 1.35rem; }
@media (max-width: 760px) {
  .navigation__liens a { background: transparent; box-shadow: inset 0 0 0 1px rgb(36 16 22 / .22); border-radius: .2rem; }
  .navigation__liens a[aria-current] { background: var(--nav-actif); box-shadow: inset 0 0 0 1.5px var(--vin); }
  .navigation__appel { border-radius: .2rem; }
}
@media (min-width: 761px) { .navigation__appel { border-radius: .2rem; } }

/* ---------------- 1. La nappe ---------------- */
.nappe { --longueur: 330svh; }
.nappe .scene__collant { background: var(--lin); color: var(--encre); }
.nappe .repli-webgl { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 100%; }
.nappe .scene__collant::after {
  content: ""; position: absolute; inset: 0; z-index: 0; background: var(--nuit); opacity: 0;
  transition: opacity .5s ease;
}
/* Le voile ne sert que si le WebGL ne tourne pas : sinon le shader fait la nuit. */
.nappe.est-soir:not(.toile-prete) .scene__collant::after { opacity: 1; }
.nappe .toile { z-index: 1; }
/* Toile abandonnée (téléphone trop lent, contexte perdu) : on la retire, l'image fixe reprend. */
.nappe:not(.toile-prete) .toile { visibility: hidden; }

/* La frise : le défilement fait passer la journée, du midi au soir. */
.frise {
  position: absolute; z-index: 2; left: var(--marge); right: var(--marge); top: calc(var(--nav-hauteur) + .7rem);
  display: flex; align-items: center; gap: .7rem; margin: 0;
  font: 700 .72rem/1 var(--corps); letter-spacing: .14em; text-transform: uppercase;
  transition: opacity .25s ease;
}
.frise__ligne { position: relative; flex: 1; height: 1px; background: currentColor; }
.frise__ligne::after {
  content: ""; position: absolute; top: -5px; left: calc(var(--p, 0) * (100% - 11px)); width: 11px; height: 11px; border-radius: 50%;
  border: 2px solid currentColor; background: var(--lin);
}
.nappe.est-soir .frise { color: var(--creme); }
.nappe.est-soir .frise__ligne::after { background: var(--nuit); }
.nappe.est-bascule .frise { opacity: 0; visibility: hidden; }

.nappe__textes { position: absolute; inset: 0; z-index: 2; pointer-events: none; }
.temps {
  position: absolute; left: var(--marge); right: var(--marge); top: calc(var(--nav-hauteur) + 2.6rem);
  opacity: 0; visibility: hidden; transform: translateY(1.1rem);
  transition: opacity .4s ease, transform .55s cubic-bezier(.16, 1, .3, 1), visibility 0s linear .4s;
}
.temps.est-actif { opacity: 1; visibility: visible; transform: none; pointer-events: auto; transition-delay: 0s; }
/* Sans le socle (mouvement réduit, sans JavaScript) : une suite de blocs dans le flux. */
html:not(.socle-actif) .nappe { height: auto; }
html:not(.socle-actif) .nappe .scene__collant { position: static; height: auto; overflow: visible; display: flex; flex-direction: column; padding-top: var(--nav-hauteur); }
html:not(.socle-actif) .nappe .toile, html:not(.socle-actif) .frise, html:not(.socle-actif) .nappe .scene__collant::after { display: none; }
html:not(.socle-actif) .nappe__textes { display: contents; }
html:not(.socle-actif) .temps { position: static; opacity: 1; visibility: visible; transform: none; padding: 2rem var(--marge); pointer-events: auto; }
html:not(.socle-actif) .temps--midi { order: 1; }
html:not(.socle-actif) .nappe picture { order: 2; display: block; }
html:not(.socle-actif) .nappe .repli-webgl { position: static; height: auto; aspect-ratio: 375 / 300; }
html:not(.socle-actif) .temps--table { order: 3; }
html:not(.socle-actif) .temps--cave { order: 4; background: var(--nuit); }

.surtitre--tampon {
  display: inline-block; padding: .42rem .7rem .4rem; margin-bottom: .95rem;
  border: 1.5px solid var(--vin); border-radius: .15rem; background: var(--lin);
}
.temps--midi h1 { font-size: clamp(4.5rem, 24.4vw, 10rem); line-height: .86; margin-bottom: 1.05rem; letter-spacing: -.012em; margin-left: -.02em; }
.temps--midi h1 span { display: block; }
.temps--midi h1 .nom-italique { font-style: italic; color: var(--vin); padding-left: .24em; }
.temps__intro { font-size: 1.06rem; line-height: 1.42; max-width: 25rem; margin-bottom: .7rem; }
.instant { font: italic 400 1.22rem/1.25 var(--titre); color: var(--vin); margin-bottom: 1rem; }
/* Les chiffres elzéviriens de la Fell se lisent mal (le 1 ressemble à un I, le 0 à un o) :
   l'heure et les prix passent en Hanken Grotesk. */
.instant time { font: 700 1rem/1 var(--corps); font-variant-numeric: tabular-nums; letter-spacing: .01em; }
.temps__actions { display: flex; flex-wrap: wrap; align-items: center; gap: .8rem 1.4rem; }
.temps h2 { font-size: clamp(2.9rem, 13.4vw, 6.4rem); line-height: .96; margin-bottom: 1.2rem; max-width: 11ch; }
.temps p { max-width: 27rem; }
.temps--table p:not(.surtitre), .temps--cave p:not(.surtitre) { font-size: 1.12rem; line-height: 1.45; }
.temps--cave h2 { color: var(--creme); }
.temps--cave p:not(.surtitre) { color: var(--creme-douce); }
.temps--cave .surtitre { color: var(--rose); }
.temps--cave .lien-fleche { color: var(--creme); }

@media (max-height: 700px) and (max-width: 760px) {
  .temps--midi h1 { font-size: clamp(3.4rem, 19vw, 5rem); margin-bottom: .7rem; }
  .temps { top: calc(var(--nav-hauteur) + 2.3rem); }
  .temps__intro { font-size: 1rem; margin-bottom: .4rem; }
  .instant { font-size: 1.1rem; margin-bottom: .6rem; }
  .temps h2 { font-size: 2.6rem; }
  .surtitre--tampon { margin-bottom: .6rem; }
}
@media (min-width: 761px) {
  .temps { right: auto; width: min(46vw, 40rem); top: 54%; translate: 0 -50%; }
  .frise { max-width: 40rem; right: auto; width: min(46vw, 40rem); }
  html:not(.socle-actif) .temps { width: auto; translate: none; }
  .temps--midi h1 { font-size: clamp(5rem, 10vw, 9.4rem); }
  .temps h2 { font-size: clamp(3rem, 6vw, 6rem); }
  .nappe .repli-webgl { object-position: 100% 60%; }
}

/* ---------------- Sections communes ---------------- */
.section { padding: clamp(4.5rem, 11vw, 8rem) var(--marge); }
.section__tete { max-width: 44rem; margin-bottom: 2.4rem; }
.section h2 { font-size: clamp(2.6rem, 1.7rem + 4vw, 5rem); line-height: 1; margin-bottom: 1rem; }
.section__tete p:not(.surtitre) { color: var(--encre-douce); font-size: 1.06rem; }
.legende { margin: .5rem 0 0; font-size: .82rem; color: var(--encre-douce); }

/* ---------------- 2. La carte : une carte imprimée, cadre double ---------------- */
.carte-resto { position: relative; z-index: 1; background: var(--lin); padding: clamp(1.1rem, 4vw, 3.5rem) clamp(.7rem, 4vw, 3.5rem); }
.carte-papier {
  position: relative; overflow: hidden; max-width: 76rem; margin: 0 auto;
  padding: clamp(2.6rem, 6vw, 5rem) clamp(1.15rem, 5vw, 4.5rem) clamp(2.2rem, 5vw, 4rem);
  background: var(--papier);
  outline: 1px solid rgb(36 16 22 / .55); outline-offset: -8px;
  border: 2px solid rgb(36 16 22 / .8);
}
.carte-papier > .rond { position: absolute; width: clamp(9rem, 44vw, 17rem); top: -1.6rem; right: -2.6rem; opacity: .15; pointer-events: none; }
.carte-resto__tete { position: relative; text-align: center; margin: 0 auto 1.6rem; max-width: 40rem; }
.carte-resto__tete h2 { font-size: clamp(3.8rem, 2.2rem + 8vw, 7rem); font-style: italic; line-height: .95; margin-bottom: .9rem; }
.mention-exemple {
  display: inline-block; margin: 0; padding: .55rem .8rem; font-weight: 700; font-size: .92rem; line-height: 1.3;
  color: var(--vin); border: 1.5px dashed var(--vin); border-radius: .15rem; background: var(--papier);
}
.carte-resto__onglets { position: relative; justify-content: center; gap: .15rem .3rem; margin-bottom: 1.6rem; border-top: 1px solid var(--carte-filet); border-bottom: 1px solid var(--carte-filet); padding: .3rem 0; }
.carte-resto__onglets [role="tab"] { min-height: 46px; padding: 0 .75rem; border: 0; border-radius: .15rem; font-size: .98rem; color: var(--encre); font-weight: 600; transition: background-color .2s ease; }
.carte-resto__onglets [role="tab"]:hover { background: var(--nav-actif); }
.carte-photo { margin: 0 0 1.4rem; }
.carte-photo img { width: 100%; aspect-ratio: 8 / 5; object-fit: cover; }
.carte-resto__panneau:focus-visible { outline-offset: 6px; }
.carte-resto__liste li {
  display: grid; grid-template-columns: minmax(0, auto) minmax(1rem, 1fr) auto; column-gap: .4rem; align-items: end;
  padding: .75rem 0; border-bottom: 0;
}
.carte-resto__liste strong { font-family: var(--titre); font-weight: 400; font-size: 1.32rem; line-height: 1.12; }
.carte-resto__liste .conduite { display: block; margin: 0; align-self: end; height: 0; border-bottom: 1.5px dotted rgb(36 16 22 / .5); transform: translateY(-.32em); }
.carte-resto__liste b { font-weight: 700; font-size: 1.04rem; color: var(--vin); white-space: nowrap; font-variant-numeric: tabular-nums; }
.carte-resto__liste span { grid-column: 1 / -1; font-size: .95rem; color: var(--encre-douce); }
.carte-resto__sous { margin: 1.4rem 0 .2rem; font: 700 .74rem/1.2 var(--corps); letter-spacing: .18em; text-transform: uppercase; color: var(--vin); }
.carte-resto__sous:first-of-type { margin-top: 0; }
.carte-resto__note { position: relative; text-align: center; font-weight: 700; color: var(--vin); margin-bottom: 0; }

@media (min-width: 900px) {
  .carte-resto__panneau:not([hidden]) { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); gap: 3rem; align-items: start; }
  .carte-resto:not(.carte-resto--onglets) .carte-resto__panneau { display: block; }
  .carte-resto__liste { grid-template-columns: minmax(0, 1fr); }
}

/* ---------------- 3. La cave : le casier de bouteilles, une lampe passe ---------------- */
.cave { --longueur: 210svh; }
.cave .scene__collant { background: var(--nuit); color: var(--creme); }
.casier, .casier__lumiere { position: absolute; inset: 0; }
/* Le cul des bouteilles couchées : quatre couches, deux décalées pour le quinconce. */
.casier {
  --cul: radial-gradient(circle 33px at 35px 30px, #0a0205 0 26%, #1a0a10 34%, #120609 62%, #2e1520 74%, #1d0b12 86%, #070103 92%, transparent 96%);
  --reflet: radial-gradient(ellipse 14px 7px at 24px 16px, rgb(255 225 225 / .14), transparent);
  background-color: #060103;
  background-image: var(--reflet), var(--reflet), var(--cul), var(--cul);
  background-size: 70px 122px;
  background-position: 0 0, 35px 61px, 0 0, 35px 61px;
}
.casier__lumiere {
  --cul: radial-gradient(circle 33px at 35px 30px, #1d040c 0 24%, #4d0b1e 36%, #7a1230 62%, #b5304d 74%, #7a1230 86%, #22050e 92%, transparent 96%);
  --reflet: radial-gradient(ellipse 14px 7px at 24px 16px, rgb(255 228 222 / .7), transparent);
  background-image: var(--reflet), var(--reflet), var(--cul), var(--cul);
  background-size: 70px 122px;
  background-position: 0 0, 35px 61px, 0 0, 35px 61px;
  --lampe-x: calc(8% + var(--p, 0) * 84%);
  --lampe-y: calc(22% + var(--p, 0) * 16%);
  -webkit-mask-image: radial-gradient(circle clamp(150px, 42vw, 340px) at var(--lampe-x) var(--lampe-y), #000 18%, rgb(0 0 0 / .4) 52%, transparent 100%);
          mask-image: radial-gradient(circle clamp(150px, 42vw, 340px) at var(--lampe-x) var(--lampe-y), #000 18%, rgb(0 0 0 / .4) 52%, transparent 100%);
}
.cave__texte {
  position: absolute; z-index: 1; left: var(--marge); right: var(--marge); bottom: 5.4rem;
  padding: 1.5rem 1.4rem .9rem; background: var(--nuit); border: 1px solid rgb(237 162 174 / .45);
}
.cave__texte .surtitre { color: var(--rose); }
.cave__texte h2 { font-size: clamp(2.5rem, 11vw, 4.6rem); line-height: 1; margin-bottom: .9rem; }
.cave__texte p:not(.surtitre) { color: var(--creme-douce); }
.cave__texte .lien-fleche { color: var(--creme); margin-bottom: .4rem; }
html:not(.socle-actif) .cave { height: auto; }
html:not(.socle-actif) .cave .scene__collant { position: relative; height: auto; overflow: hidden; padding: 12rem var(--marge) 3rem; }
html:not(.socle-actif) .cave__texte { position: relative; left: auto; right: auto; bottom: auto; }
@media (max-height: 700px) { .cave__texte { bottom: 4.6rem; padding-top: 1.1rem; } .cave__texte h2 { font-size: 2.3rem; } }
@media (min-width: 761px) {
  .cave__texte { right: auto; width: min(44vw, 36rem); bottom: 50%; transform: translateY(50%); padding: 2.4rem 2.2rem 1.6rem; }
  html:not(.socle-actif) .cave__texte { width: auto; max-width: 36rem; transform: none; }
}

/* ---------------- 4. L'épicerie ---------------- */
.epicerie { position: relative; background: var(--papier); overflow: hidden; }
.epicerie > .rond { position: absolute; width: clamp(14rem, 62vw, 26rem); right: -5.5rem; bottom: -4.5rem; opacity: .14; pointer-events: none; }
.epicerie__corps { position: relative; max-width: 40rem; }
.epicerie__corps > p:not(.surtitre) { color: var(--encre-douce); font-size: 1.06rem; }
.rayons { list-style: none; margin: 1.6rem 0 0; padding: 0; border-top: 1px solid var(--carte-filet); }
.rayons li { padding: .95rem 0; border-bottom: 1px solid var(--carte-filet); font: italic 400 1.45rem/1.15 var(--titre); }
.rayons small { display: block; margin-top: .25rem; font: 400 .95rem/1.4 var(--corps); color: var(--encre-douce); }

/* ---------------- 5. Ce qui reste à remplacer ---------------- */
.remplacer { background: var(--lin); }
.remplacer__liste { list-style: none; margin: 0; padding: 0; display: grid; gap: 1.5rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.remplacer__liste li { display: grid; grid-template-columns: 2.6rem minmax(0, 1fr); column-gap: .85rem; align-items: start; }
.remplacer__liste .rond { width: 2.6rem; }
.remplacer__liste strong { display: block; font: 400 1.4rem/1.15 var(--titre); margin-bottom: .25rem; }
.remplacer__liste p { margin: 0; color: var(--encre-douce); font-size: .98rem; }

/* ---------------- 6. Venir ---------------- */
.infos { background: var(--papier); display: grid; gap: 2.4rem; grid-template-columns: minmax(0, 1fr); padding-bottom: clamp(3rem, 7vw, 6rem); }
.numero { position: relative; width: 11.5rem; height: 11.5rem; display: grid; place-items: center; margin: 0 0 1.2rem -.6rem; }
.numero .rond { position: absolute; inset: 0; width: 100%; height: 100%; opacity: .62; }
.numero span { position: relative; font: 300 3.7rem/1 var(--corps); letter-spacing: -.03em; color: var(--encre); }
.infos h2 { font-size: clamp(2.2rem, 1.5rem + 3.2vw, 3.8rem); max-width: 14ch; }
.infos__lignes { margin: 1.4rem 0 1.6rem; padding: 0; border-top: 1px solid var(--carte-filet); }
.infos__lignes div { display: grid; grid-template-columns: 6.6rem minmax(0, 1fr); gap: .6rem; padding: .7rem 0; border-bottom: 1px solid var(--carte-filet); }
.infos__lignes dt { font-weight: 700; }
.infos__lignes dd { margin: 0; }
.infos__lignes a { display: inline-flex; align-items: center; min-height: 44px; margin: -.65rem 0; font-weight: 600; text-underline-offset: 3px; }
.infos__incertain { font-style: italic; color: var(--encre-douce); }
.infos__actions { display: flex; flex-wrap: wrap; gap: .7rem; }
.infos__actions .bouton { flex: 1 1 11rem; }
.carte-google { display: block; border: 2px solid rgb(36 16 22 / .8); width: 100%; min-height: 22rem; height: 100%; }
@media (min-width: 900px) { .infos { grid-template-columns: minmax(0, 1fr) minmax(0, 1.2fr); gap: 4rem; } }

/* ---------------- Pied de page ---------------- */
.pied { background: var(--nuit); color: var(--creme-douce); padding: 2.6rem var(--marge) 6.4rem; font-size: .94rem; }
.pied__nom { display: flex; align-items: center; gap: .6rem; font: italic 400 1.7rem/1.1 var(--titre); color: var(--creme); margin-bottom: 1rem; }
.pied__nom .rond { width: 1.7rem; color: var(--rose); }
.pied p { max-width: 42rem; margin-bottom: .6rem; }
.pied__credit { font-size: .84rem; }
.pied a { color: var(--creme); text-underline-offset: 3px; }

/* Le filigrane reste discret, et redevient plein au survol et au clavier. */
.filigrane-demo { opacity: .88; transition: opacity .2s ease; }
.filigrane-demo:hover, .filigrane-demo:focus-visible { opacity: 1; }
