/* ==========================================================================
   Carte d'hiver v2, look Noël (23/11/2026) : chargée seulement par menu.html
   À retirer avec le mode hiver : ce fichier, winter-menu.js et le
   <main class="wm"> de menu.html (la carte de printemps complète est dans
   backups/2026-11-23-avant-mode-hiver/menu.html).
   ========================================================================== */

.wm {
    --wm-fir: #22340d;
    --wm-fir-deep: #162207;
    --wm-gold: #f4cc22;
    --wm-cream: #f6f0d8;
    --wm-cream-soft: rgba(246, 240, 216, 0.82);
    --wm-ink-soft: rgba(26, 26, 14, 0.76);
    --wm-rule: rgba(59, 84, 27, 0.2);
    --wm-nav-h: 76px; /* hauteur du menu du haut, recalculée par winter-menu.js */
    --wm-gutter: clamp(1.25rem, 5vw, 4rem);
    --wm-max: 1180px;
    display: block;
    background: var(--linen);
    color: var(--dark);
}

/* --------------------------------------------------------------------------
   1. En-tête : nuit d'hiver sur Union Square, et le traîneau de la mamie
      (illustrations générées avec Codex dans le style de la mamie au bonnet)
   -------------------------------------------------------------------------- */

/* Assez bas pour qu'on voie la barre de rubriques et le début de la carte dès l'ouverture */
.wm-hero {
    --wm-sky: #0a2e29;
    position: relative;
    overflow: hidden;
    isolation: isolate;
    height: max(480px, 66svh);
    background: var(--wm-sky);
    color: var(--wm-cream);
}

.wm-scene {
    position: absolute;
    z-index: -3;
    inset: 0;
    display: block;
    transform-origin: 50% 100%;
    will-change: transform;
}

/* Téléphone : scène verticale calée par le haut (la lune reste sous le menu du haut) */
.wm-scene img {
    display: block;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 50% 0%;
}

/* Ciel assombri en haut (titre et menu du haut lisibles), neige fondue dans la page en bas */
.wm-hero::after {
    content: "";
    position: absolute;
    z-index: -2;
    inset: 0;
    background:
        linear-gradient(180deg, rgba(4, 22, 19, 0.6) 0%, rgba(4, 22, 19, 0) 36%),
        linear-gradient(0deg, var(--linen) 0%, rgba(244, 241, 224, 0) 7%);
    pointer-events: none;
}

.wm-snow {
    position: absolute;
    z-index: -1;
    inset: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

.wm-hero-copy {
    position: relative;
    max-width: var(--wm-max);
    margin: 0 auto;
    padding: calc(var(--wm-nav-h) + clamp(1.1rem, 3.5vh, 2.4rem)) var(--wm-gutter) 0;
    will-change: transform, opacity;
}

.wm-title {
    margin: 0;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(3.2rem, 8vw, 6rem);
    line-height: 0.92;
    letter-spacing: -0.01em;
    color: var(--wm-cream);
    text-shadow: 0 2px 28px rgba(3, 20, 17, 0.6);
    text-wrap: balance;
}

.wm-lede {
    max-width: 24ch;
    margin: 0.9rem 0 0;
    font-size: clamp(1rem, 1.5vw, 1.15rem);
    line-height: 1.5;
    color: var(--wm-cream);
    text-shadow: 0 1px 14px rgba(3, 20, 17, 0.8);
    text-wrap: pretty;
}

.wm-call {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
    min-height: 48px;
    padding: 0.8rem 1.35rem;
    border-radius: 2px;
    background: var(--wm-gold);
    box-shadow: 0 10px 22px -12px rgba(8, 18, 6, 0.65);
    color: var(--dark);
    font-family: var(--sans);
    font-size: 1rem;
    font-weight: 400;
    line-height: 1;
    text-decoration: none;
    white-space: nowrap;
    transition: transform 0.35s var(--ease-out), background-color 0.35s var(--ease-out), box-shadow 0.35s var(--ease-out);
}

.wm-call strong {
    font-weight: 500;
}

.wm-call span {
    font-variant-numeric: tabular-nums;
}

.wm-call:hover {
    background-color: #ffd83a;
    box-shadow: 0 14px 26px -12px rgba(8, 18, 6, 0.7);
    transform: translateY(-2px);
}

.wm-call:focus-visible {
    outline: 2px solid var(--wm-gold);
    outline-offset: 3px;
}

/* Sur téléphone, la précommande est posée sur la neige, en bas de la scène */
.wm-hero-call--sky {
    display: none;
    margin-top: 1.6rem;
}

.wm-hero-call--snow {
    position: absolute;
    z-index: 1;
    bottom: max(0.9rem, 2.5%);
    left: 50%;
    background: var(--dark);
    color: var(--wm-cream);
    transform: translateX(-50%);
}

.wm-hero-call--snow:hover {
    background-color: var(--green-dark);
    transform: translateX(-50%) translateY(-2px);
}

.wm-hero-call--snow:focus-visible {
    outline-color: var(--dark);
}

/* Tablette et ordinateur : bande panoramique basse, centrée ; titre et précommande dans le ciel */
@media (min-width: 601px) {
    .wm-hero {
        height: clamp(440px, 43vw, 72vh);
    }

    .wm-scene img {
        object-position: 50% 62%;
    }

    .wm-hero-copy {
        padding-top: calc(var(--wm-nav-h) + clamp(1.6rem, 6vh, 3.5rem));
    }

    .wm-lede {
        max-width: 34ch;
    }

    .wm-hero-call--sky {
        display: inline-flex;
    }

    .wm-hero-call--snow {
        display: none;
    }
}

/* Le traîneau : posé devant la lune tant que le script ne l'a pas pris en main
   (et pour les personnes qui préfèrent moins d'animations) */
.wm-sleigh {
    position: absolute;
    z-index: 0;
    top: 9%;
    right: 3%;
    width: 32%;
    max-width: 320px;
    height: auto;
    transform: scaleX(-1);
    pointer-events: none;
}

/* En vol : calque fixe au-dessus de la page (ajouté à <body> par winter-menu.js) */
.wm-sky {
    --wm-sleigh-w: 100vw;
    position: fixed;
    z-index: 25;
    inset: 0;
    overflow: hidden;
    pointer-events: none;
    visibility: hidden;
}

.wm-sky.is-on {
    visibility: visible;
}

.wm-sky canvas {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
}

.wm-sky .wm-sleigh {
    top: 0;
    right: auto;
    left: 0;
    width: var(--wm-sleigh-w);
    max-width: none;
    filter: drop-shadow(0 0 14px rgba(255, 214, 120, 0.38));
    transform-origin: 50% 50%;
    will-change: transform;
}

@media (min-width: 601px) {
    .wm-sky {
        --wm-sleigh-w: min(60vw, 960px);
    }
}

/* --------------------------------------------------------------------------
   2. Barre de rubriques : reste sous le menu du haut et suit la lecture
   -------------------------------------------------------------------------- */

.wm-tabs {
    position: sticky;
    z-index: 30;
    top: var(--wm-nav-h);
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.65rem var(--wm-gutter);
    overflow-x: auto;
    background: var(--linen);
    border-bottom: 1px solid var(--wm-rule);
    scrollbar-width: none;
}

.wm-tabs::-webkit-scrollbar {
    display: none;
}

.wm-tab {
    flex: 0 0 auto;
    display: inline-flex;
    align-items: center;
    min-height: 44px;
    padding: 0 1.1rem;
    border: 1px solid rgba(59, 84, 27, 0.35);
    border-radius: 2px;
    color: var(--green);
    font-family: var(--sans);
    font-size: 0.95rem;
    font-weight: 500;
    line-height: 1;
    text-decoration: none;
    transition: background-color 0.3s var(--ease-out), color 0.3s var(--ease-out), border-color 0.3s var(--ease-out);
}

.wm-tab:hover {
    background-color: rgba(59, 84, 27, 0.08);
}

.wm-tab:focus-visible {
    outline: 2px solid var(--green);
    outline-offset: 2px;
}

.wm-tab[aria-current="true"] {
    background-color: var(--green);
    border-color: var(--green);
    color: var(--wm-cream);
}

/* Sur ordinateur, quand le menu du haut revient au-dessus de la carte, il prend un fond crème
   pour former un seul en-tête net avec la barre de rubriques (rien ne défile derrière le logo) */
@media (min-width: 841px) {
    body.menu-page:not(.dark-section) .nav.scrolled:not(.nav-hidden) {
        background: var(--linen);
    }
}

/* Sur ordinateur, le menu du haut se cache en descendant : la barre prend sa place,
   puis redescend sous lui quand il revient (mêmes durées que le menu du haut) */
@media (min-width: 841px) {
    .wm-tabs {
        top: 0;
        transition: top 0.38s cubic-bezier(0.4, 0, 0.2, 1);
    }

    .wm.is-nav-shown .wm-tabs {
        top: var(--wm-nav-shown-h, 60px);
        transition: top 0.32s cubic-bezier(0, 0, 0.2, 1);
    }
}

/* --------------------------------------------------------------------------
   3. La carte
   -------------------------------------------------------------------------- */

.wm-menu {
    display: grid;
    gap: clamp(3rem, 6vw, 4.5rem);
    max-width: var(--wm-max);
    margin: 0 auto;
    padding: clamp(2.4rem, 6vw, 4.5rem) var(--wm-gutter) clamp(3rem, 6vw, 5rem);
}

.wm-section {
    scroll-margin-top: calc(var(--wm-nav-h) + 4.5rem);
}

.wm-head {
    display: flex;
    flex-wrap: wrap;
    align-items: baseline;
    justify-content: space-between;
    gap: 0.35rem 1.5rem;
    padding-bottom: 0.85rem;
    border-bottom: 1.5px solid var(--green);
}

.wm-head h2 {
    margin: 0;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(2.2rem, 4.6vw, 3.1rem);
    line-height: 1;
    color: var(--green);
}

.wm-head p {
    margin: 0;
    font-size: 0.95rem;
    line-height: 1.4;
    color: var(--wm-ink-soft);
}

.wm-list {
    margin: 0;
    padding: 0;
    list-style: none;
}

.wm-item {
    --thumb: 84px;
    position: relative;
    display: grid;
    grid-template-columns: var(--thumb) minmax(0, 1fr);
    align-items: center;
    column-gap: 1rem;
    padding: 1.05rem 0;
    border-bottom: 1px solid var(--wm-rule);
}

.wm-thumb {
    position: relative;
    display: block;
    width: var(--thumb);
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: 50%;
    background: var(--egg);
    box-shadow: 0 12px 18px -10px rgba(26, 26, 14, 0.45);
}

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

/* Photo détourée (assiette ronde sur fond transparent) */
.wm-thumb--cutout {
    overflow: visible;
    background: transparent;
    box-shadow: none;
}

.wm-thumb--cutout img {
    object-fit: contain;
    filter: drop-shadow(0 9px 7px rgba(26, 26, 14, 0.3));
    transform: scale(1.1);
}

/* En attendant les photos de Sam */
.wm-thumb[data-photo-pending] {
    box-shadow: inset 0 0 0 3px var(--linen), 0 12px 18px -10px rgba(26, 26, 14, 0.4);
}

.wm-line {
    display: flex;
    align-items: baseline;
    gap: 0.55rem;
}

.wm-name {
    margin: 0;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(1.45rem, 3vw, 1.85rem);
    line-height: 1.05;
    color: var(--dark);
}

.wm-dots {
    flex: 1 1 0.75rem;
    min-width: 0.75rem;
    border-bottom: 2px dotted rgba(59, 84, 27, 0.4);
    transform: translateY(-0.3em);
}

.wm-price {
    margin: 0;
    font-family: var(--serif);
    font-size: clamp(1.35rem, 2.8vw, 1.7rem);
    line-height: 1;
    color: var(--green);
    white-space: nowrap;
}

.wm-tag {
    margin: 0.3rem 0 0;
    font-size: 0.8rem;
    font-weight: 500;
    line-height: 1.3;
    color: var(--green);
}

.wm-desc {
    max-width: 48ch;
    margin: 0.3rem 0 0;
    font-size: 0.92rem;
    line-height: 1.5;
    color: var(--wm-ink-soft);
    text-wrap: pretty;
}

/* Salées en 2 colonnes, desserts et boissons côte à côte sur grand écran */
.wm-duo {
    display: grid;
    gap: clamp(3rem, 6vw, 4.5rem);
}

@media (min-width: 720px) {
    .wm-list--two {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        column-gap: clamp(2rem, 4vw, 3.5rem);
    }
}

@media (min-width: 900px) {
    .wm-item {
        --thumb: 108px;
        column-gap: 1.25rem;
        padding: 1.3rem 0;
    }

    .wm-duo {
        grid-template-columns: minmax(0, 1.12fr) minmax(0, 0.88fr);
        align-items: start;
    }
}

/* --------------------------------------------------------------------------
   4. Boissons chaudes et soupe : le tableau vert et or du stand
   -------------------------------------------------------------------------- */

.wm-board {
    position: relative;
    overflow: hidden;
    padding: clamp(1.5rem, 4vw, 2.3rem) clamp(1.3rem, 4vw, 2.3rem) clamp(1.4rem, 3.5vw, 2rem);
    border-radius: 6px;
    box-shadow: 0 34px 60px -34px rgba(10, 24, 6, 0.75);
    background:
        radial-gradient(110% 70% at 100% 0%, rgba(244, 204, 34, 0.12), rgba(244, 204, 34, 0) 65%),
        var(--wm-fir);
    color: var(--wm-cream);
}

.wm-board .wm-head {
    border-bottom-color: rgba(244, 204, 34, 0.55);
}

.wm-board .wm-head h2 {
    color: var(--wm-gold);
}

.wm-board-list {
    margin: 0.35rem 0 0;
    padding: 0;
    list-style: none;
}

.wm-board-list li {
    display: flex;
    align-items: baseline;
    gap: 0.55rem;
    padding: 0.8rem 0;
    border-bottom: 1px solid rgba(246, 240, 216, 0.12);
}

.wm-board-name,
.wm-board-title {
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(1.3rem, 2.4vw, 1.5rem);
    line-height: 1.1;
    color: var(--wm-cream);
}

.wm-board-title {
    margin: 1.5rem 0 0;
    scroll-margin-top: calc(var(--wm-nav-h) + 4.5rem);
}

.wm-size {
    font-size: 0.95rem;
    font-weight: 500;
    color: var(--wm-cream-soft);
}

.wm-board .wm-dots {
    border-bottom-color: rgba(244, 204, 34, 0.42);
}

.wm-board .wm-price {
    color: var(--wm-gold);
}

.wm-board-note {
    margin: 0.85rem 0 0;
    font-size: 0.88rem;
    line-height: 1.45;
    color: var(--wm-cream-soft);
}

/* --------------------------------------------------------------------------
   5. Précommande et infos pratiques
   -------------------------------------------------------------------------- */

.wm-preorder {
    position: relative;
    overflow: visible;
    overflow-x: clip;
    background: var(--wm-gold);
    color: var(--dark);
    scroll-margin-top: calc(var(--wm-nav-h) + 4.5rem);
}

/* Le traîneau repasse en filant le long du bord haut du bloc de précommande,
   sans croiser le texte (piloté par winter-menu.js) */
.wm-sleigh-mini {
    position: absolute;
    z-index: 0;
    top: 0;
    left: 0;
    width: clamp(124px, 14vw, 190px);
    height: auto;
    filter: drop-shadow(0 8px 6px rgba(26, 26, 14, 0.25));
    transform: translate(-120%, -50%);
    pointer-events: none;
    will-change: transform;
}

.wm-band-trail {
    position: absolute;
    z-index: 0;
    top: -90px;
    left: 0;
    width: 100%;
    height: calc(100% + 90px);
    pointer-events: none;
}

.wm-preorder-inner {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 1.1rem 2rem;
    max-width: var(--wm-max);
    margin: 0 auto;
    padding: clamp(2rem, 5vw, 3rem) var(--wm-gutter);
}

.wm-preorder h2 {
    margin: 0;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(2rem, 4.4vw, 2.8rem);
    line-height: 1;
}

.wm-preorder p {
    margin: 0.5rem 0 0;
    font-size: 0.95rem;
    line-height: 1.45;
    color: rgba(26, 26, 14, 0.8);
}

.wm-call--dark {
    background: var(--dark);
    color: var(--wm-cream);
}

.wm-call--dark:hover {
    background-color: var(--green-dark);
}

.wm-call--dark:focus-visible {
    outline-color: var(--dark);
}

.wm-notes {
    max-width: var(--wm-max);
    margin: 0 auto;
    padding: clamp(2.25rem, 5vw, 3.5rem) var(--wm-gutter) clamp(3rem, 6vw, 4.5rem);
}

.wm-notes h2 {
    margin: 0 0 1.1rem;
    font-family: var(--serif);
    font-weight: 400;
    font-size: clamp(1.6rem, 3.2vw, 2rem);
    line-height: 1.05;
    color: var(--green);
}

.wm-notes-grid {
    display: grid;
    gap: 1.1rem 2.5rem;
}

.wm-notes-grid p {
    max-width: 52ch;
    margin: 0;
    font-size: 0.9rem;
    line-height: 1.6;
    color: var(--wm-ink-soft);
}

.wm-notes-grid strong {
    display: block;
    margin-bottom: 0.15rem;
    font-weight: 500;
    color: var(--dark);
}

@media (min-width: 900px) {
    .wm-notes-grid {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}

/* --------------------------------------------------------------------------
   6. Secret de La Poulette (appui long sur sa photo)
   -------------------------------------------------------------------------- */

.wm-item [data-secret-hold] {
    cursor: pointer;
    touch-action: manipulation;
    -webkit-touch-callout: none;
    -webkit-user-select: none;
    user-select: none;
}

.wm-secret-reveal {
    position: absolute;
    z-index: 2;
    inset: 0.45rem 0;
    display: grid;
    place-content: center;
    gap: 0.3rem;
    border-radius: 6px;
    background: var(--wm-fir);
    color: var(--wm-cream);
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transform: scale(0.98);
    transition: opacity 0.35s var(--ease-out), transform 0.35s var(--ease-out), visibility 0s linear 0.35s;
}

.wm-item.is-secret-revealed .wm-secret-reveal {
    opacity: 1;
    visibility: visible;
    transform: none;
    transition-delay: 0s;
}

.wm-secret-reveal strong {
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--wm-gold);
}

.wm-secret-reveal span {
    font-family: var(--serif);
    font-size: 2rem;
    line-height: 1;
}

.wm-secret-reveal small {
    font-size: 0.8rem;
    color: var(--wm-cream-soft);
}

/* --------------------------------------------------------------------------
   7. Mobile et mouvements réduits
   -------------------------------------------------------------------------- */

@media (max-width: 560px) {
    .wm-tabs {
        justify-content: flex-start;
    }
}

@media (prefers-reduced-motion: reduce) {
    .wm-sleigh-mini {
        display: none;
    }

    .wm-call,
    .wm-tab,
    .wm-secret-reveal {
        transition: none;
    }
}
