@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:wght@300;400;500;600&family=Jost:wght@300;400;500;600&family=Marcellus&family=Marcellus+SC&display=swap');

/* ─── RESET & BASE ─── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg-main:       #2b2b2b;
  --bg-sidebar:    #232323;
  --bg-card:       #303030;
  --gold:          #c9a84c;
  --gold-light:    #e0c070;
  --gold-dim:      #8a6f2e;
  --text-primary:  #e8e0d0;
  --text-muted:    #888880;
  --text-dim:      #555;
  --border:        rgba(201,168,76,0.18);
  --border-subtle: rgba(255,255,255,0.06);
  --radius:        4px;
  --sidebar-w:     215px;
  --header-h:      66px;
  --transition:    0.22s ease;
}

html, body {
  height: 100%;
  background: var(--bg-main);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 14px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }

/* ─── LAYOUT SHELL ─── */
.app {
  display: grid;
  grid-template-rows: var(--header-h) 1fr;
  grid-template-columns: var(--sidebar-w) 1fr;
  grid-template-areas:
    "header  header"
    "sidebar main";
  min-height: 100vh;
}

/* ─── HEADER ─── */
.app-header {
  grid-area: header;
  display: flex;
  align-items: center;
  padding: 0 28px;
  background: var(--bg-main);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 100;
  min-height: 64px;     /* permet aux bouteilles de remonter sans déborder */
}

/* Real SVG logo — centred absolutely in the header */
.header-logo {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
}

/* ─── LANGUAGE SWITCHER (3 drapeaux discrets, opacity .5 par défaut) ─── */
.header-langs {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-right: 16px;     /* petite respiration avant les bouteilles */
  border-radius: 6px;
}

/* ─── HEADER BOTTLES — sur la même ligne que les drapeaux, alignées au BAS
       du header. Au repos : seul le col + amorce du corps visibles. Au hover :
       le clip grandit VERS LE HAUT (corps + étiquette révélés) sans dépasser
       sous la ligne du header. Tout reste contenu dans la hauteur du header.
       ──────────────────────────────────────────────────────────────────── */
.header-bottles {
  display: flex;
  align-items: flex-end;       /* ligne du bas du header */
  align-self: flex-end;
  gap: 5px;
  margin-right: auto;          /* pousse le reste vers la droite */
  /*margin-bottom: 4px;           léger gap entre cols et bordure header */
  position: relative;
}

.hb-bottle {
  display: block;
  position: relative;
  width: 16px;
  height: 22px;                /* slot fixe — réservation de layout */
  text-decoration: none;
  cursor: pointer;
}

/* Clip = la fenêtre visible. Anchored BOTTOM du slot. À l'état repos elle
   fait 22px. Au hover elle grandit vers le HAUT pour révéler le reste. */
.hb-bottle-clip {
  display: block;
  position: absolute;
  bottom: 0;                   /* ← anchored bottom → grandit vers le haut */
  left: 0;
  width: 16px;
  height: 22px;
  overflow: hidden;
  transition: height 0.35s cubic-bezier(.4, 0, .2, 1);
}

/* La bouteille : full 55px, anchored TOP du clip. Au repos seul son top
   (col + shoulder) est visible. Quand le clip grandit (vers le haut),
   son top monte aussi → expose plus de la bouteille (corps + étiquette). */
.hb-bottle-img,
.hb-bottle svg.hb-bottle-img {
  position: absolute;
  top: 0;
  left: 50%;
  width: auto;
  height: 55px;                /* hauteur "pleine" de la bouteille */
  max-height: 55px;
  max-width: 25px;
  object-fit: contain;
  object-position: top;
  transform: translateX(-50%);
  opacity: 0.5;
  filter: saturate(.7) drop-shadow(0 1px 2px rgba(0,0,0,0.4));
  transition: opacity 0.35s ease, filter 0.35s ease;
  pointer-events: none;
}

/* HOVER : clip grandit de 22px → 55px (bottom-anchored = grandit vers le haut).
   La bouteille devient pleinement visible dans le header, col en haut,
   corps + étiquette dessous, base au niveau de la ligne du bas. */
.hb-bottle:hover .hb-bottle-clip,
.hb-bottle:focus-visible .hb-bottle-clip {
  height: 55px;
  z-index: 300;
}
.hb-bottle:hover .hb-bottle-img,
.hb-bottle:hover svg.hb-bottle-img,
.hb-bottle:focus-visible .hb-bottle-img,
.hb-bottle:focus-visible svg.hb-bottle-img {
  opacity: 1;
  filter: saturate(1) drop-shadow(0 4px 1px rgba(0,0,0,0.7));
}

.hb-bottle:hover,
.hb-bottle:focus-visible { z-index: 300; }

/* Tooltip custom (remplace le tooltip système). S'affiche SOUS la bouteille,
   coins arrondis, bg-main + text-primary, fine bordure gold. Décalé 150ms
   pour ne pas s'afficher dès le moindre survol fugace. */
.hb-bottle::after {
  content: attr(data-tooltip);
  position: absolute;
  top: calc(100% + 10px);                /* sous la ligne du header */
  left: 50%;
  transform: translateX(-50%) translateY(-4px);
  background: var(--bg-main);
  color: var(--text-primary);
  border: 1px solid rgba(201,168,76,.35);   /* gold-dim subtil */
  border-radius: 5px;
  padding: 6px 11px;
  font-family: 'Jost', sans-serif;
  font-size: 9px;
  text-transform:uppercase;
  font-weight: 400;
  letter-spacing: 0.04em;
  white-space: nowrap;
  opacity: 0;
  pointer-events: none;
  box-shadow: 0 4px 14px rgba(0,0,0,.4);
  z-index: 400;
  transition: opacity 0.2s ease 0.15s, transform 0.2s ease 0.15s;
}
.hb-bottle:hover::after,
.hb-bottle:focus-visible::after {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
/* Petite flèche pointant vers la bouteille (haut du tooltip) */
.hb-bottle::before {
  content: '';
  position: absolute;
  top: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  width: 0;
  height: 0;
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-bottom: 6px solid rgba(201,168,76,.35);
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease 0.15s;
  z-index: 401;
}
.hb-bottle:hover::before,
.hb-bottle:focus-visible::before { opacity: 1; }

.hl-flag {
  display: inline-flex;
  line-height: 0;
  border-radius: 2px;
  overflow: hidden;
  opacity: 0.5;
  filter: saturate(.85);
  transition: opacity .2s ease, filter .2s ease, transform .2s ease;
}

.hl-flag img {
  width: 22px;
  height: 16px;
  display: block;
  object-fit: cover;
}

.hl-flag:hover {
  opacity: 0.95;
  filter: saturate(1);
  transform: translateY(-1px);
}

/* Drapeau de la langue active : pleinement visible + fin liseré or en bas */
.hl-flag.is-active {
  opacity: 1;
  filter: saturate(1);
  /*box-shadow: inset 0 -2px 0 var(--gold);*/
}

.logo-svg {
  /* viewBox="0 0 141 58"  →  scale to fit header height with breathing room */
  height: 42px;
  width: auto;
  color: var(--gold);           /* currentColor used inside SVG */
  display: block;
}

.header-welcome {
  margin-left: auto;
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 300;
  letter-spacing: 0.01em;
}

.header-welcome strong {
  color: var(--text-primary);
  font-weight: 500;
}

/* ─── SIDEBAR ─── */
.app-sidebar {
  grid-area: sidebar;
  background: var(--bg-sidebar);
  padding-top: 24px;
  border-right: 1px solid var(--border-subtle);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 11px;
  padding: 13px 22px;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.02em;
  position: relative;
  text-decoration: none;   /* covers <a> tags */
  white-space: nowrap;     /* évite le reflow 2 lignes→1 ligne pendant le chargement de la police (FOUT) */
}

.nav-item:hover {
  background: rgba(201,168,76,0.06);
  color: var(--text-primary);
}

.nav-item.active {
  background: rgba(201,168,76,0.10);
  color: var(--gold);
  font-weight: 500;
}

.nav-item.active::before {
  content: '';
  position: absolute;
  right: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--gold);
  border-radius: 0 2px 2px 0;
}

.nav-icon {
  width: 18px; height: 18px;
  flex-shrink: 0; opacity: 0.7;
}

.nav-item.active .nav-icon,
.nav-item:hover .nav-icon { opacity: 1; }

/* ─── MAIN ─── */
.app-main {
  grid-area: main;
  padding: 36px 40px 60px;
  overflow-y: auto;
  /* overflow-y:auto fait calculer overflow-x à `auto` par défaut → un tooltip
     (.demo-tip) près du bord droit déclenchait une scrollbar horizontale. On la
     supprime explicitement (le header sticky est hors de .app-main → sans effet
     sur lui). Les tooltips près du bord sont clippés de quelques px, sans barre. */
  overflow-x: hidden;
}

/* ─── SECTION TITLES ─── */
.section-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 22px;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--text-primary);
  margin-bottom: 20px;
}

/* ─── RECENT ACTIVITY ─── */
.section-activity { margin-bottom: 1px; }

.activity-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 20px;
}

.portfolio-value {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 300;
}

.portfolio-value strong {
  color: var(--gold);
  font-weight: 600;
  font-size: 14px;
}

/* Bandeau Total Account Value au-dessus du Order Status,
   aligné à droite, séparé par une fine ligne or. */
.account-value-strip {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0 0 14px;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--border-subtle);
}

/* Ligne séparatrice entre chaque section du dashboard (même style que
   .account-value-strip). Le :not(:last-child) évite la ligne en bas de page.
   Override le margin-bottom propre aux sections-status / order pour garder
   un rythme vertical cohérent. */
.app-main > section:not(:last-child) {
  padding-bottom: 42px;
  margin-bottom: 32px;
  border-bottom: 1px solid var(--border-subtle);
}
/*
.account-value-strip .portfolio-value {
  letter-spacing: .08em;
  text-transform: uppercase;
  font-size: 11.5px;
}
.account-value-strip .portfolio-value strong {
  font-size: 15px;
  letter-spacing: .04em;
  margin-left: 4px;
}
*/
.activity-table { width: 100%; border-collapse: collapse; }

.activity-table thead tr { border-bottom: 1px solid var(--border-subtle); }

.activity-table th {
  text-align: left;
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--text-muted);
  padding: 0 0 12px;
}

.activity-table th:last-child,
.activity-table td:last-child { text-align: right; }

.activity-table td {
  padding: 15px 0;
  font-size: 13.5px;
  font-weight: 300;
  color: var(--text-primary);
  border-bottom: 1px solid var(--border-subtle);
  transition: background 0.18s;
}

.activity-table tr:last-child td { border-bottom: none; }
.activity-table td.amount { font-weight: 500; }

/* Lignes cliquables : hover discret + cursor pointer + chevron à droite.
   Le clic sur n'importe quelle cellule de la row déclenche la navigation via JS. */
.activity-table tr.activity-row { cursor: pointer; transition: background .15s ease; }
.activity-table tr.activity-row:hover,
.activity-table tr.activity-row:focus-visible { background: rgba(201,168,76,0.06); outline: none; }
.activity-table tr.activity-row:hover .activity-link,
.activity-table tr.activity-row:focus-visible .activity-link { color: var(--gold); }
.activity-table .activity-link {
  color: inherit;
  text-decoration: none;
  position: relative;
  padding-right: 18px;
  display: inline-block;
}
.activity-table .activity-link::after {
  content: '›';
  position: absolute;
  right: 0; top: 50%;
  transform: translateY(-55%);
  font-size: 18px;
  color: var(--gold);
  opacity: 0;
  transition: opacity .15s ease, transform .15s ease;
}
.activity-table tr.activity-row:hover .activity-link::after,
.activity-table tr.activity-row:focus-visible .activity-link::after {
  opacity: 1;
  transform: translateY(-55%) translateX(3px);
}

/* ─── QUICK ORDER ─── */
.section-order { margin-bottom: 44px; }

/* Collection tabs */
.collection-tabs {
  display: flex;
  gap: 2px;
  margin-bottom: 24px;
  border-bottom: 1px solid var(--border-subtle);
}

.col-tab {
  background: transparent;
  border: none;
  border-bottom: 2px solid transparent;
  margin-bottom: -1px;
  padding: 10px 22px;
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
  cursor: pointer;
  transition: color var(--transition), border-color var(--transition);
}

.col-tab:hover { color: var(--text-primary); }

.col-tab.active {
  color: var(--gold);
  border-bottom-color: var(--gold);
}

/* ─── Variante --wrap : tabs sur plusieurs lignes (pour les catalogues
   avec beaucoup de catégories, ex. accessoires.php). Évite le scroll
   horizontal — essentiel pour les libellés DE longs (« Individualisierbare
   Verpackung », « Terrassendekoration » etc.). */
.collection-tabs.collection-tabs--wrap {
  flex-wrap: wrap;
  gap: 4px 2px;            /* gap vertical entre rangées · gap horizontal entre tabs */
  border-bottom: none;     /* la border-bottom n'est plus pertinente quand les tabs wrappent */
  padding: 4px 0 10px;
  border-bottom: 1px solid var(--border-subtle);
}
.collection-tabs--wrap .col-tab {
  flex: 0 0 auto;
  padding: 8px 14px;       /* plus compact pour packer plus de tabs par ligne */
  letter-spacing: 0.1em;
  border-radius: 3px;
  border: 1px solid transparent;
  margin-bottom: 0;
  white-space: normal;     /* autorise wrap interne du libellé pour les mots très longs */
  text-align: center;
  min-height: 38px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}
.collection-tabs--wrap .col-tab:hover {
  background: rgba(201,168,76,.06);
  border-color: var(--border-subtle);
}
.collection-tabs--wrap .col-tab.active {
  background: rgba(201,168,76,.12);
  border: 1px solid var(--gold);
  border-bottom-color: var(--gold);  /* override de la règle de base sans `--wrap` */
}
.collection-tabs--wrap .col-tab small {
  margin-top: 3px !important;
  letter-spacing: 0.08em !important;
}

/* Collection panels */
.collection-panel { display: none; }
.collection-panel.active { display: block; }

/* Bottle grid */
.order-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 20px;
}

/* Single bottle card */
.order-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  padding: 18px 12px 16px;
  background: rgba(255,255,255,0.03);
  border: 1px solid var(--border-subtle);
  border-radius: 6px;
  transition: border-color var(--transition), background var(--transition);
}

.order-card:hover {
  border-color: var(--border);
  background: rgba(201,168,76,0.04);
}

.bottle-wrap {
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.bottle-img {
  max-height: 130px;
  max-width: 70px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 4px 10px rgba(0,0,0,0.75));
}

.bottle-placeholder {
  height: 130px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.card-name {
  font-size: 11.5px;
  font-weight: 400;
  color: var(--text-muted);
  text-align: center;
  line-height: 1.4;
  /* Noms courts filtrés (1 ligne) côté index.php → on réserve 1 ligne pour
     aligner verticalement price/stepper/bouton entre toutes les cards.
     collections.php / accessoires.php ont leur propre min-height inline.
     line-clamp:3 conservé comme garde-fou si un nom non mappé déborde. */
  min-height: calc(1.4em * 1);
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

/* Sélecteur de format ‹ Bouteille 0,75 L › — sit entre le nom et le prix.
   Texte blanc, arrows blanc. Si un seul format → flèches masquées (display:none),
   on ne montre que le label centré. */
.format-switch {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  width: 100%;
  /* Hauteur constante = celle de la version avec flèches (.fmt-arrow ≈ 20px).
     Sans ça, une cuvée mono-format (is-single, flèches masquées) a une rangée
     plus basse → le bloc prix/stepper/boutons en dessous n'est plus aligné
     entre cartes voisines. */
  min-height: 20px;
  font-family: 'Jost', sans-serif;
  font-size: 10.5px;
  font-weight: 400;
  letter-spacing: .06em;
  color: #fff;
  text-transform: uppercase;
  margin-top: -4px;
}

.format-switch .fmt-arrow {
  background: transparent;
  border: none;
  color: #fff;
  font-size: 16px;
  line-height: 1;
  padding: 2px 6px;
  cursor: pointer;
  transition: color .15s ease, transform .15s ease, opacity .15s ease;
  user-select: none;
}
.format-switch .fmt-arrow:hover { color: var(--gold); transform: translateY(-1px); }
.format-switch .fmt-arrow:active { transform: translateY(0); }

.format-switch .fmt-label {
  flex: 0 1 auto;
  min-width: 0;
  max-width: 100%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  color: #fff;
  transition: color .25s ease;
}

/* Un seul format : on n'affiche aucune flèche, juste le label. */
.format-switch.is-single .fmt-arrow { display: none; }

/* Animation discrète au changement de format (pulse du label en gold). */
.format-switch.is-changing .fmt-label { color: var(--gold); }

/* Prix optionnel — quand présent, sit au-dessus du stepper. width:100 % +
   text-align:center pour que le texte reste centré comme avant (le card
   étant en align-items:center, un width auto fonctionnait, mais width:100 %
   est plus prévisible). */
.card-price { width: 100%; text-align: center; }

/* Quantity controls — pinné en bas du card via margin-top:auto pour que les
   stepper + bouton Add restent alignés horizontalement avec les cards voisines,
   y compris quand .card-price est absent. */
.qty-controls {
  display: flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  width: 100%;
  margin-top: auto;
}

.qty-btn {
  width: 30px;
  height: 30px;
  background: transparent;
  border: none;
  color: var(--gold);
  font-size: 17px;
  cursor: pointer;
  transition: background var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.qty-btn:hover { background: rgba(201,168,76,0.12); }

.qty-value {
  flex: 1;
  text-align: center;
  font-size: 13px;
  color: var(--text-primary);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  height: 30px;
  line-height: 30px;
}

.btn-add {
  width: 100%;
  background: transparent;
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  color: var(--gold);
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  padding: 8px 0;
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
  /* Le libellé (« Commander » → « ✓ » au succès) reste TOUJOURS sur une seule
     ligne : sur les cartes étroites (grille minmax(130px)), un libellé long qui
     passe à la ligne grandissait le bouton → la carte → toute la rangée
     (align-items:stretch). nowrap + ellipsis fige la hauteur. */
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.btn-add:hover { background: var(--gold); color: #1a1a1a; }

/* ─── ORDER STATUS ─── */
.section-status { margin-bottom: 44px; }

/* Trois rangées (badges / dots / labels) partagent la MÊME grille 5 colonnes
   afin d'aligner chaque cellule verticalement. Centre col 1 = 10 %,
   centre col 5 = 90 % → la ligne (bg + fill) part de 10 % à 90 % (width 80 %). */
.status-badges {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: end;
  margin-bottom: 28px;
}

.status-badge {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  justify-self: center;
  text-align: center;
}

.badge-label {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
}

.status-badge.active .badge-label { color: var(--text-primary); }

.badge-pill {
  background: var(--gold);
  color: #1a1a1a;
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.06em;
  padding: 5px 14px;
  border-radius: 20px;
  display: inline-block;
}

.badge-date {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 300;
}

/* Progress timeline */
.progress-track {
  position: relative;
  display: flex;
  align-items: center;
  margin-bottom: 12px;
}

.progress-line-bg {
  position: absolute;
  top: 50%; left: 10%; right: 10%;          /* = centre col 1 et centre col 5 */
  height: 2px;
  background: var(--border-subtle);
  transform: translateY(-50%);
}

.progress-line-fill {
  position: absolute;
  top: 50%; left: 10%;
  height: 2px;
  background: linear-gradient(90deg, var(--gold-dim), var(--gold));
  transform: translateY(-50%);
  z-index: 1;
  width: 0;
  transition: width 1s ease;
}

.progress-steps {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: center;
  width: 100%;
  position: relative;
  z-index: 2;
}

.progress-dot {
  width: 20px; height: 20px;
  border-radius: 50%;
  background: var(--bg-main);
  border: 2px solid var(--text-dim);
  justify-self: center;
  flex-shrink: 0;
}

.progress-dot.done {
  background: var(--gold-dim);
  border-color: var(--gold-dim);
}

.progress-dot.current {
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 0 5px rgba(201,168,76,0.2), 0 0 14px rgba(201,168,76,0.4);
  animation: pulse-dot 2.2s ease-in-out infinite;
}

/* État "Completed/Closed" : le dot est plein, mais l'animation s'arrête.
   Modificateur appliqué au .progress-dot.current quand status = 'completed'. */
.progress-dot.current.closed {
  animation: none;
  background: var(--gold);
  border-color: var(--gold);
  box-shadow: 0 0 0 5px rgba(201,168,76,0.2), 0 0 8px rgba(201,168,76,0.25);
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 4px rgba(201,168,76,0.15), 0 0 12px rgba(201,168,76,0.35); }
  50%       { box-shadow: 0 0 0 8px rgba(201,168,76,0.08), 0 0 22px rgba(201,168,76,0.5); }
}

.progress-labels {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  align-items: start;
}

.progress-labels span {
  font-size: 11.5px;
  color: var(--text-muted);
  font-weight: 300;
  text-align: center;
  justify-self: center;
}

/* ─── FOOTER ─── */
.app-footer {
  background: #1e1e1e;
  border-top: 1px solid var(--border-subtle);
  padding: 40px 60px 28px;
  position: relative;
  overflow: hidden;
}

/* Rose décorative (index.php uniquement) — la tige touche bottom: 0 */
.footer-rose {
  position: absolute;
  right: 15px;
  bottom: 0;
  height: 300px;
  width: auto;
  pointer-events: none;
  user-select: none;
  z-index: 1;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 32px;
  margin-bottom: 36px;
}

.footer-col-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 14px;
}

.footer-col p,
.footer-col a {
  display: block;
  font-size: 12px;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.9;
  transition: color var(--transition);
}

.footer-col a:hover { color: var(--gold-light); }

.social-icons { display: flex; gap: 12px; margin-top: 6px; }

.social-icon {
  width: 28px; height: 28px;
  border-radius: 50%;
  border: 1px solid rgba(201,168,76,0.3);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-muted);   /* pilote le currentColor des SVG (fill + stroke) */
  transition: border-color var(--transition), background var(--transition), color var(--transition);
}

.social-icon:hover {
  border-color: var(--gold);
  background: rgba(201,168,76,0.1);
  color: var(--gold);
}

.social-icon svg { width: 17px; height: 17px; }

/* Les icônes sociales sont des <a> dans .footer-col → `.footer-col a { display:block }`
   écrasait le flex et décentrait le SVG. On restaure le centrage (spécificité 0,0,2,0). */
.social-icons .social-icon { display: flex; align-items: center; justify-content: center; }

.footer-bottom {
  text-align: center;
  font-size: 11px;
  color: var(--text-dim);
  font-weight: 300;
  letter-spacing: 0.05em;
  border-top: 1px solid var(--border-subtle);
  padding-top: 20px;
}

/* ═══════════════════════════════════════════
   ORDERS PAGE
   ═══════════════════════════════════════════ */

.orders-layout {
  display: grid;
  grid-template-columns: 1fr 360px;
  gap: 24px;
  align-items: start;
  animation: fadeUp 0.45s ease both;
}

.orders-card,
.summary-card {
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 28px 24px;
}

.order-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 18px 0;
}

/* ─── Thumbnails commande (orders.php · order_details.php) ───────────────
   Cuvée / accessoire : ombre douce comme sur collections.php pour donner
   du relief aux PNG/SVG sur fond sombre. */
.orders-thumb,
.order-detail-thumb {
  filter: drop-shadow(0 2px 5px rgba(0,0,0,0.7));
  transition: filter .25s ease, transform .25s ease;
}
.orders-thumb:hover,
.order-detail-thumb:hover {
  filter: drop-shadow(0 4px 10px rgba(0,0,0,0.75));
}

/* Item list */
.order-item-list { display: flex; flex-direction: column; }

.order-item {
  display: grid;
  grid-template-columns: 72px 1fr;
  gap: 16px;
  padding: 18px 0;
}

.order-item.has-top-border { border-top: 1px solid var(--border-subtle); }

.oi-thumb {
  display: flex;
  align-items: center;
  justify-content: center;
  /*background: rgba(0,0,0,0.2);*/
  border-radius: 6px;
  overflow: hidden;
  height: 140px;
}

.oi-thumb img {
  max-height: 106px;
  max-width: 64px;
  width: auto;
  object-fit: contain;
  filter: drop-shadow(0 3px 3px rgba(0,0,0,0.7));
}

.oi-thumb-fallback {
  height: 110px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.oi-details {
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
}

.oi-name {
  font-family: 'Cormorant Garamond', serif;
  font-size: 15px;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.02em;
  margin-bottom: 4px;
}

.oi-meta {
  display: flex;
  justify-content: space-between;
  gap: 12px;
}

.oi-label {
  font-size: 12px;
  font-weight: 300;
  color: var(--text-muted);
}

.oi-val {
  font-size: 12px;
  font-weight: 400;
  color: var(--text-primary);
  white-space: nowrap;
}

.oi-total-row {
  margin-top: 4px;
  padding-top: 6px;
  border-top: 1px solid var(--border-subtle);
}

.oi-total { font-weight: 600; }

/* Shipping note */
.shipping-note {
  font-size: 12px;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.6;
  margin-top: 4px;
}

.shipping-note a {
  color: var(--gold);
  transition: color var(--transition);
}

.shipping-note a:hover { color: var(--gold-light); }

/* Form controls */
.form-group { margin-bottom: 16px; }
.form-group:last-child { margin-bottom: 0; }

.form-label {
  display: block;
  font-size: 12px;
  font-weight: 400;
  color: var(--text-primary);
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}

.form-input {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 300;
  padding: 11px 14px;
  outline: none;
  transition: border-color var(--transition);
}

.form-input:focus { border-color: var(--border); }

.form-select-wrap { position: relative; }

.form-select {
  width: 100%;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 300;
  padding: 11px 38px 11px 14px;
  outline: none;
  appearance: none;
  cursor: pointer;
  transition: border-color var(--transition);
}

.form-select:focus { border-color: var(--border); }

/* Popup d'options de la liste native : la surface héritée était quasi blanche
   → texte clair (var(--text-primary)) sur fond clair = illisible. On force un
   fond gris un peu plus clair que le gris du champ (background-color seul). */
.form-select option { background-color: #3a3a3a; }

.select-chevron {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  width: 14px;
  height: 14px;
  color: var(--text-muted);
  pointer-events: none;
}

/* Summary card */
.summary-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.03em;
  color: var(--text-primary);
}

.summary-lines { display: flex; flex-direction: column; gap: 12px; }

.summary-line {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
}

.sl-label {
  font-size: 12.5px;
  font-weight: 300;
  color: var(--text-muted);
}

.sl-val {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  white-space: nowrap;
}

.sl-discount { color: #d98080; }

/* Total block */
.summary-total-block {
  margin: 22px 0 20px;
  text-align: center;
}

.summary-total-label {
  font-size: 13px;
  font-weight: 300;
  color: var(--text-muted);
  letter-spacing: 0.03em;
  margin-bottom: 6px;
}

.summary-total-amount {
  font-family: 'Cormorant Garamond', serif;
  font-size: 40px;
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.01em;
  line-height: 1;
}

/* Confirm button */
.btn-confirm {
  width: 100%;
  padding: 18px 12px;
  background: linear-gradient(135deg, #a07830, #d4a84c, #a07830);
  background-size: 200% 100%;
  border: none;
  border-radius: var(--radius);
  color: #1a1400;
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  text-align: center;
  cursor: pointer;
  line-height: 1.6;
  transition: background-position 0.4s ease, box-shadow 0.3s, opacity 0.2s;
  box-shadow: 0 4px 20px rgba(201,168,76,0.25);
}

.btn-confirm:hover {
  background-position: 100% 0;
  box-shadow: 0 6px 28px rgba(201,168,76,0.45);
}

.btn-confirm:active { opacity: 0.85; }

.btn-confirm:disabled {
  opacity: 0.7;
  cursor: default;
  box-shadow: none;
}

/* ═══════════════════════════════════════════
   PRODUCT PAGE
   ═══════════════════════════════════════════ */

/* Extend main for product: no max-width constraint, remove default padding-top */
.product-main { padding-top: 24px; }

/* Portfolio bar (top-right) */
.product-portfolio-bar {
  display: flex;
  justify-content: flex-end;
  margin-bottom: 28px;
  animation: fadeUp 0.35s ease both;
}

/* Two-column hero (par défaut : image + info) ; trois colonnes quand le
   widget Performance est présent (image + info + perf). Bascule via la
   classe .has-perf posée en PHP sur .product-hero. */
.product-hero {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 52px;
  align-items: start;
  animation: fadeUp 0.45s ease 0.05s both;
}
.product-hero.has-perf {
  grid-template-columns: 200px 1fr 260px;
  gap: 36px;
}

/* ─── LEFT: bottle image ─── */
.product-img-col { position: sticky; top: calc(var(--header-h) + 24px); }

.product-img-wrap {
  /*background: linear-gradient(160deg, #1e1e1e 0%, #272720 100%);*/
  border-radius: 8px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 540px;
  padding: 20px 16px;
  /*box-shadow: inset 0 0 60px rgba(0,0,0,0.5), 0 8px 40px rgba(0,0,0,0.4);*/
}

.product-bottle-img {
  width: 100%;
  max-width: 170px;
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 2px 5px rgba(0,0,0,0.7));
  transition: transform 0.5s ease;
}

.product-img-wrap:hover .product-bottle-img {
  transform: scale(1.03) translateY(-4px);
}

.product-bottle-fallback {
  height: 380px;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ─── RIGHT: info column ─── */
.product-info-col {
  padding-top: 4px;
  max-width: 520px;
}

/* ─── B2B Performance widget (3e colonne du grid .product-hero) ───────── */
.product-perf-card {
  width: 100%;
  background: linear-gradient(180deg, rgba(201,168,76,0.06), rgba(0,0,0,0.18));
  border: 1px solid rgba(201,168,76,0.22);
  border-radius: 6px;
  padding: 14px 14px 12px;
  font-family: 'Jost', sans-serif;
  color: var(--text-primary, #e6e6e6);
  box-shadow: 0 4px 18px rgba(0,0,0,0.25);
  z-index: 2;
}
.product-perf-card .ppc-header {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
  padding-bottom: 10px;
  margin-bottom: 10px;
  border-bottom: 1px solid rgba(201,168,76,0.15);
}
.product-perf-card .ppc-pulse {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--gold, #c9a84c);
  box-shadow: 0 0 0 0 rgba(201,168,76,0.6);
  animation: ppcPulse 1.8s ease-out infinite;
  flex-shrink: 0;
}
@keyframes ppcPulse {
  0%   { box-shadow: 0 0 0 0 rgba(201,168,76,0.55); }
  70%  { box-shadow: 0 0 0 7px rgba(201,168,76,0); }
  100% { box-shadow: 0 0 0 0 rgba(201,168,76,0); }
}
.product-perf-card .ppc-title {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold, #c9a84c);
}
.product-perf-card .ppc-sub {
  flex-basis: 100%;
  font-size: 10px;
  color: var(--text-muted, #999);
  letter-spacing: 0.04em;
  margin-top: 2px;
}

.product-perf-card .ppc-kpis {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
  margin-bottom: 12px;
}
.product-perf-card .ppc-kpi {
  background: rgba(0,0,0,0.18);
  border-radius: 4px;
  padding: 8px 6px 7px;
  text-align: center;
}
.product-perf-card .ppc-kpi-val {
  font-family: 'Cormorant Garamond', serif;
  font-size: 22px;
  font-weight: 600;
  color: var(--gold, #c9a84c);
  line-height: 1.05;
}
.product-perf-card .ppc-kpi-val .ppc-unit {
  font-size: 12px;
  color: var(--text-muted, #999);
  margin-left: 1px;
}
.product-perf-card .ppc-kpi-lbl {
  font-size: 9px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted, #999);
  margin-top: 3px;
}

.product-perf-card .ppc-forecast {
  background: rgba(201,168,76,0.05);
  border-left: 2px solid var(--gold, #c9a84c);
  border-radius: 0 4px 4px 0;
  padding: 8px 10px;
  margin-bottom: 10px;
}
.product-perf-card .ppc-forecast-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  line-height: 1.4;
}
.product-perf-card .ppc-forecast-row + .ppc-forecast-row { margin-top: 4px; }
.product-perf-card .ppc-forecast-icon {
  color: var(--gold, #c9a84c);
  width: 12px;
  text-align: center;
  font-size: 12px;
}
.product-perf-card .ppc-forecast-lbl {
  color: var(--text-muted, #999);
  letter-spacing: 0.04em;
}
.product-perf-card .ppc-forecast-val {
  margin-left: auto;
  color: var(--text-primary, #e6e6e6);
  font-weight: 500;
}
.product-perf-card .ppc-forecast-highlight {
  color: var(--gold, #c9a84c);
  font-weight: 600;
}

.product-perf-card .ppc-meta {
  font-size: 10px;
  color: var(--text-muted, #999);
}
.product-perf-card .ppc-meta-row {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  padding: 4px 0;
}
.product-perf-card .ppc-meta-row + .ppc-meta-row {
  border-top: 1px dashed rgba(255,255,255,0.06);
}
.product-perf-card .ppc-meta-lbl {
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.product-perf-card .ppc-meta-val {
  color: var(--text-primary, #e6e6e6);
  font-weight: 500;
  text-transform: none;
  letter-spacing: 0;
}
.product-perf-card .ppc-meta-val.ppc-up   { color: #7eb86e; }
.product-perf-card .ppc-meta-val.ppc-down { color: #d57a7a; }

/* Sous le seuil tablette : le grid 3 colonnes redevient 1 colonne empilée.
   La card Performance passe en dessous des 2 colonnes principales. */
@media (max-width: 980px) {
  .product-hero.has-perf {
    grid-template-columns: 1fr;
    gap: 24px;
  }
}

/* Product name — Marcellus SC + dégradé or multi-stops + reflet de lumière.
   Layout (sizing / spacing / uppercase / flex) conservé ; seul l'effet visuel
   du remplissage et des ombres est repris du site de référence. */
.product-name {
  font-family: 'Marcellus SC', 'Cormorant Garamond', serif;
  font-size: 52px;
  font-weight: 600;
  line-height: 1.0;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 22px;
  display: flex;
  flex-direction: column;

  /* ── Effet : dégradé or à 5 stops clipped sur le texte ── */
  background: linear-gradient(135deg,
    #c9a84c 10%,
    #a67d33 35%,
    #c09541 50%,
    #d1a54a 65%,
    #ac8336 100%);
  -webkit-background-clip: text;
          background-clip: text;
  -webkit-text-fill-color: transparent;
                  color: transparent;

  /* Empilement d'ombres : relief bas (assombrissement), highlight haut
     (rebord lumineux), halo doux. Ordre = du plus proche au plus loin. 
  text-shadow:
    0 -1px 0 rgb(194, 152, 89),
    0  1px 0 rgba(20, 12, 0, 0.95),
    1px 1px 0 rgba(20, 12, 0, 0.92),
    0  2px 2px rgba(0, 0, 0, 0.65),
    0  4px 5px rgba(0, 0, 0, 0.45),
    0  0   1px rgba(255, 255, 255, 1),
    0  0   8px rgba(255, 210, 100, 0.18);

   drop-shadow agit sur la silhouette du dégradé (text-shadow seul ne traverse
     pas un text-fill transparent — on le combine avec drop-shadow pour la
     profondeur sous le glyphe). 
  filter:
    drop-shadow(0 1px 0 rgba(0, 0, 0, 0.95))
    drop-shadow(0 2px 2px rgba(0, 0, 0, 0.75))
    drop-shadow(0 6px 10px rgba(0, 0, 0, 0.35)); */
}

.product-name span { display: block; }

/* Description */
.product-desc {
  font-size: 13.5px;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 400px;
  font-family: 'Marcellus';
}

/* Divider */
.product-divider {
  height: 1px;
  background: var(--border-subtle);
  margin: 26px 0;
}

/* ─── Specs grid 2×2 ─── */
.specs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  border-top: 1px solid var(--border-subtle);
  border-left: 1px solid var(--border-subtle);
  font-family: 'Marcellus';
}

.spec-cell {
  padding: 16px 20px 16px 0;
  border-right: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
}

.spec-cell:nth-child(odd) { padding-left: 24px; }
.spec-cell:nth-child(even) { padding-left: 24px; }

.spec-label {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 6px;
}

.spec-value {
  font-size: 13.5px;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.5;
}

/* ─── B2B Ordering ─── */
.b2b-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.03em;
  margin-bottom: 18px;
}

.b2b-controls { margin-bottom: 18px; }

/* Qty stepper — wider than card variant */
.b2b-qty {
  display: inline-flex;
  align-items: center;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.b2b-qty .qty-btn {
  width: 44px;
  height: 44px;
  background: transparent;
  border: none;
  color: var(--gold);
  font-size: 20px;
  cursor: pointer;
  transition: background var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}

.b2b-qty .qty-btn:hover { background: rgba(201,168,76,0.1); }

.b2b-qty .qty-value {
  width: 56px;
  text-align: center;
  font-size: 15px;
  font-weight: 400;
  color: var(--text-primary);
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
  height: 44px;
  line-height: 44px;
  pointer-events: none;
}

/* Price row */
.b2b-price-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.b2b-price-label {
  font-size: 12.5px;
  font-weight: 300;
  color: var(--text-muted);
}

.b2b-price-val {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

/* Add to Portfolio CTA */
.btn-add-portfolio {
  width: 100%;
  padding: 17px 24px;
  background: linear-gradient(135deg, #a07830, #d4a84c, #a07830);
  background-size: 200% 100%;
  border: none;
  border-radius: var(--radius);
  color: #1a1200;
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  cursor: pointer;
  transition: background-position 0.4s ease, box-shadow 0.3s, opacity 0.2s;
  box-shadow: 0 4px 22px rgba(201,168,76,0.28);
}

.btn-add-portfolio:hover {
  background-position: 100% 0;
  box-shadow: 0 6px 32px rgba(201,168,76,0.48);
}

.btn-add-portfolio:active { opacity: 0.85; }
.btn-add-portfolio:disabled { opacity: 0.7; cursor: default; box-shadow: none; }

/* TEST — Swap hover/non-hover SCOPÉ à #btnAddPortfolio (product.php seulement).
   La spécificité #id > .class garantit que cart.php / d'autres pages avec
   .btn-add-portfolio gardent leur comportement standard. */
#btnAddPortfolio {
  background-position: 100% 0;
  box-shadow: 0 6px 32px rgba(201,168,76,0.48);
}
#btnAddPortfolio:hover {
  background-position: 0% 0;
  box-shadow: 0 4px 22px rgba(201,168,76,0.28);
}

/* ─── Bouton secondaire « Ajouter au devis » sur fiche produit ─────────────
   Petit, outline or, aligné à droite sous le bouton principal.        */
.btn-add-quote-product {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-family: 'Jost', sans-serif;
  font-size: 10px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 6px 14px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background var(--transition), color var(--transition);
}
.btn-add-quote-product:hover {
  background: var(--gold);
  color: #1a1a1a;
}
.btn-add-quote-product:disabled { opacity: 0.6; cursor: default; }

/* ─── Tasting Notes ─── */
.tasting-title {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--gold);
  margin-bottom: 24px;
}

.tasting-list { display: flex; flex-direction: column; gap: 22px; }

.tasting-item {
  display: flex;
  align-items: flex-start;
  gap: 18px;
}

.tasting-icon {
  flex-shrink: 0;
  width: 36px;
  height: 36px;
  color: var(--gold);
  opacity: 0.75;
}

.tasting-icon svg { width: 100%; height: 100%; }

.tasting-text {
  font-size: 13px;
  font-weight: 300;
  color: var(--text-muted);
  line-height: 1.65;
  padding-top: 6px;
}

.tasting-text strong {
  font-weight: 600;
  color: var(--text-primary);
}

/* ─── TOAST ─── */
.toast {
  position: fixed;
  bottom: 30px; right: 30px;
  background: #1e1e1e;
  border: 1px solid var(--gold);
  border-radius: var(--radius);
  padding: 12px 20px;
  color: var(--text-primary);
  font-size: 13px;
  box-shadow: 0 8px 32px rgba(0,0,0,0.5);
  transform: translateY(80px);
  opacity: 0;
  transition: transform 0.3s ease, opacity 0.3s ease;
  z-index: 999;
}

.toast.show { transform: translateY(0); opacity: 1; }

/* ─── SCROLLBAR ─── */
::-webkit-scrollbar { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-main); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }
::-webkit-scrollbar-thumb:hover { background: var(--gold-dim); }

/* ─── ENTRY ANIMATIONS ─── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.section-activity { animation: fadeUp 0.45s ease both; }
.section-order     { animation: fadeUp 0.45s ease 0.1s both; }
.section-status    { animation: fadeUp 0.45s ease 0.2s both; }

/* ═══════════════════════════════════════════
   ANALYTICS PAGE
   ═══════════════════════════════════════════ */

.analytics-main { padding-top: 32px; }

.analytics-stack {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* ── Shared analytics card ── */
.an-card {
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  animation: fadeUp 0.45s ease both;
}

.an-card:nth-child(2) { animation-delay: 0.08s; }
.an-card:nth-child(3) { animation-delay: 0.16s; }

/* ── Card header row ── */
.an-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 26px 16px;
}

.an-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 24px;
  font-weight: 500;
  color: var(--text-primary);
  letter-spacing: 0.02em;
}

/* Period selector */
.period-select-wrap {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.period-select {
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 12px;
  font-weight: 400;
  padding: 7px 30px 7px 14px;
  appearance: none;
  cursor: pointer;
  outline: none;
  transition: border-color var(--transition);
}

.period-select:hover { border-color: var(--gold); }

.period-chevron {
  position: absolute;
  right: 9px;
  pointer-events: none;
  width: 12px;
  height: 12px;
  color: var(--text-muted);
}

/* ── Chart canvas area ── */
.an-chart-wrap {
  padding: 0 26px 26px;
  position: relative;
}

#salesChart {
  width: 100% !important;
  max-height: 280px;
}

/* ── Key Metrics row ── */
.metrics-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
}

.metric-card {
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  padding: 24px 22px 22px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  animation: fadeUp 0.45s ease 0.08s both;
  transition: border-color var(--transition);
}

.metric-card:hover { border-color: rgba(201,168,76,0.25); }

.metric-eyebrow {
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  font-weight: 500;
  color: var(--gold);
  letter-spacing: 0.03em;
  margin-bottom: 2px;
}

.metric-label {
  font-size: 11.5px;
  font-weight: 300;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  line-height: 1.3;
}

.metric-value {
  font-family: 'Cormorant Garamond', serif;
  font-size: 42px;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1;
  margin: 6px 0 4px;
  letter-spacing: -0.01em;
}

.metric-value.gold { color: var(--gold); }

.metric-sub {
  font-size: 12px;
  font-weight: 300;
  color: var(--text-muted);
  margin-top: 2px;
}

/* Trend arrow SVG */
.metric-trend {
  margin-top: 6px;
}

.metric-trend svg {
  width: 48px;
  height: 26px;
  overflow: visible;
}

/* Bottle icon inside metric */
.metric-bottle-icon {
  margin: 8px 0 4px;
  color: var(--gold);
  opacity: 0.75;
}

.metric-bottle-icon svg {
  width: 40px;
  height: 70px;
}

/* ── Geographic Distribution ── */
.geo-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  padding: 22px 26px 0;
}

.geo-subtitle {
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
}

.geo-map-wrap {
  position: relative;
  padding: 16px 26px 26px;
  min-height: 320px;
}

/* SVG world map */
#worldMap {
  width: 100%;
  height: auto;
  display: block;
}

/* Country paths */
.map-country {
  fill: none;
  stroke: rgba(201,168,76,0.22);
  stroke-width: 0.6;
  transition: fill 0.25s, stroke 0.25s;
}

.map-country.active {
  fill: rgba(201,168,76,0.55);
  stroke: rgba(201,168,76,0.7);
}

.map-country.semi {
  fill: rgba(201,168,76,0.22);
  stroke: rgba(201,168,76,0.4);
}

/* Geo labels + glowing dots */
.geo-label-group { pointer-events: none; }

.geo-dot {
  animation: geo-pulse 2.4s ease-in-out infinite;
}

@keyframes geo-pulse {
  0%, 100% { opacity: 1;   r: 5; }
  50%       { opacity: 0.6; r: 7; }
}

.geo-label-text {
  font-family: 'Cormorant Garamond', serif;
  font-size: 13px;
  font-weight: 500;
  fill: var(--text-primary);
  letter-spacing: 0.03em;
}

/* ═══════════════════════════════════════════
   ACCOUNT MANAGER PAGE
   ═══════════════════════════════════════════ */
 
.account-main { padding-top: 32px; }
 
.account-stack {
  display: flex;
  flex-direction: column;
  gap: 22px;
  max-width: 680px;
}
 
/* ── Shared card ── */
.ac-card {
  background: rgba(255,255,255,0.025);
  border: 1px solid var(--border-subtle);
  border-radius: 8px;
  overflow: hidden;
  animation: fadeUp 0.45s ease both;
  position: relative;
}
 
/* Gold noise texture overlay — top-right corner (CSS only) */
.ac-card::after {
  content: '';
  position: absolute;
  top: 0; right: 0;
  width: 220px; height: 120px;
  background: radial-gradient(ellipse at top right,
    rgba(201,168,76,0.18) 0%,
    rgba(140,110,30,0.08) 40%,
    transparent 70%);
  pointer-events: none;
  border-radius: 0 8px 0 0;
}
 
/* ── Card header ── */
.ac-card-header {
  padding: 22px 26px 18px;
  border-bottom: 1px solid var(--border-subtle);
}
 
.ac-card-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 26px;
  letter-spacing: 0.02em;
  display: flex;
  gap: 8px;
  align-items: baseline;
}
 
.act-light {
  font-weight: 300;
  color: var(--text-primary);
  font-style: italic;
}
 
.act-bold {
  font-weight: 700;
  color: var(--text-primary);
}
 
/* ══ MERCHANT IDENTITY ══ */
.identity-body {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 28px 30px 30px;
  gap: 24px;
}
 
.identity-left {
  display: flex;
  flex-direction: column;
  gap: 0;
}
 
.identity-logo-wrap {
  display: flex;
  flex-direction: column;
  gap: 2px;
}
 
.identity-logo-champagne {
  font-family: 'Jost', sans-serif;
  font-size: 10px;
  font-weight: 400;
  letter-spacing: 0.32em;
  color: var(--gold);
  text-transform: uppercase;
  margin-bottom: 2px;
  margin-left: 44px;
}
 
.identity-gardet-svg {
  width: 180px;
  height: auto;
  color: var(--gold);
  margin-bottom: 10px;
}
 
.identity-dealer-name {
  font-family: 'Jost', sans-serif;
  font-size: 28px;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-primary);
  margin-top: 4px;
}
 
/* Certified Partner badge — image webp principale + SVG fallback redessiné.
   Les deux partagent la même taille pour ne pas casser le layout au swap. */
.identity-badge-wrap { flex-shrink: 0; }

.certified-badge-img,
.certified-badge-svg {
  height: 120px;
  width: auto;
  display: block;
  filter: drop-shadow(0 4px 18px rgba(201,168,76,0.32));
  user-select: none;
}
 
/* ══ COMMERCIAL TERMS TABLE ══ */
.ct-table {
  display: flex;
  flex-direction: column;
}
 
.ct-row {
  display: grid;
  grid-template-columns: 180px 1fr;
  border-bottom: 1px solid var(--border-subtle);
}
 
.ct-row:last-child { border-bottom: none; }
 
.ct-key {
  padding: 18px 20px 18px 26px;
  font-size: 13.5px;
  font-weight: 400;
  color: var(--text-muted);
  border-right: 1px solid var(--border-subtle);
  display: flex;
  align-items: center;
}
 
.ct-val {
  padding: 18px 24px;
  font-size: 14px;
  font-weight: 400;
  color: var(--text-primary);
  display: flex;
  align-items: center;
}
 
/* Manager cell */
.ct-row-manager .ct-key { align-items: flex-start; padding-top: 22px; }
 
.ct-manager {
  display: flex;
  align-items: stretch;       /* la photo s'étire à la hauteur du bloc manager-info */
  gap: 16px;
  padding: 18px 24px;
}
 
/* Manager photo */
.manager-photo-wrap {
  flex-shrink: 0;
  width: 72px;
  min-height: 72px;           /* plancher ; s'étire à la hauteur du bloc infos via align-self */
  align-self: stretch;
  border-radius: 4px;
  overflow: hidden;
  background: rgba(201,168,76,0.07);
  border: 1px solid var(--border-subtle);
}
 
.manager-photo {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top center;
}
 
.manager-photo-fallback {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
}
 
.manager-photo-fallback svg { width: 100%; height: 100%; }
 
/* Manager info */
.manager-info {
  display: flex;
  flex-direction: column;
  gap: 3px;
  padding-top: 2px;
}
 
.manager-title-label {
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.05em;
  color: var(--text-muted);
}
 
.manager-name {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: 0.01em;
  margin-bottom: 3px;
}
 
.manager-contact {
  display: block;
  font-size: 12px;
  font-weight: 300;
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition);
  line-height: 1.7;
}
 
.manager-contact:hover { color: var(--gold); }
 
/* ══ LEGAL & CONTRACTS ══ */
.legal-list { display: flex; flex-direction: column; }
 
.legal-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 24px 20px 26px;
  transition: background var(--transition);
}
 
.legal-row:hover { background: rgba(201,168,76,0.04); }
 
.legal-row.has-top-border { border-top: 1px solid var(--border-subtle); }
 
.legal-label {
  font-size: 15px;
  font-weight: 400;
  color: var(--gold);
  text-decoration: none;
  letter-spacing: 0.01em;
  transition: color var(--transition);
}
 
.legal-label:hover { color: var(--gold-light); }
 
/* PDF download icon button */
.legal-pdf-btn {
  flex-shrink: 0;
  width: 36px;
  height: 42px;
  color: var(--text-muted);
  text-decoration: none;
  transition: color var(--transition), transform var(--transition);
  display: flex;
  align-items: center;
  justify-content: center;
}
 
.legal-pdf-btn svg { width: 30px; height: 36px; }
 
.legal-pdf-btn:hover {
  color: var(--gold);
  transform: translateY(-2px);
}

/* ═══════════════════════════════════════════
   SUCCESS / CONFIRMATION PAGE
   ═══════════════════════════════════════════ */
 
/* Override body bg for success — allow hero image to read through */
.success-page { background: #111; }
 
/* Header slight transparency over the image */
.app-header--success {
  background: rgba(25,22,18,0.82);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom-color: rgba(201,168,76,0.12);
}
 
/* Success main takes the full right column,
   no padding — the hero is edge-to-edge */
.success-main {
  grid-area: main;
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}
 
/* ── Hero block ── */
.success-hero {
  position: relative;
  flex: 1;
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: flex-end;
}
 
/* Background photo */
.success-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  /* CSS-only fallback when no photo is provided */
  background-color: #1a150a;
  background-image:
    url('img/champagne-flute.jpg'),
    radial-gradient(ellipse 60% 80% at 55% 20%,
      rgba(201,168,76,0.22) 0%,
      rgba(140,100,20,0.12) 35%,
      transparent 70%),
    linear-gradient(170deg,
      #1e1a10 0%,
      #151210 40%,
      #0e0c09 100%);
}
 
/* Dark gradient — strong at bottom, fades at top */
.success-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(14,12,9,0.10)  0%,
    rgba(14,12,9,0.18)  30%,
    rgba(14,12,9,0.62)  58%,
    rgba(14,12,9,0.92)  78%,
    rgba(14,12,9,0.98) 100%
  );
  z-index: 1;
}
 
/* Bubbles canvas — fills the hero */
.success-bubbles {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 2;
  pointer-events: none;
}
 
/* ── Content (text + buttons) ── */
.success-content {
  position: relative;
  z-index: 3;
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 0 32px 80px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0;
  animation: successFadeUp 0.9s cubic-bezier(0.22,1,0.36,1) both;
}
 
@keyframes successFadeUp {
  from { opacity: 0; transform: translateY(32px); }
  to   { opacity: 1; transform: translateY(0); }
}
 
/* Thank you heading */
.success-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: clamp(32px, 5vw, 52px);
  font-weight: 500;
  color: var(--gold);
  line-height: 1.1;
  letter-spacing: 0.02em;
  margin-bottom: 24px;
  text-shadow: 0 2px 24px rgba(0,0,0,0.8);
  /* Toujours sur une seule ligne : pas de retour à la ligne ; si le nom du
     partenaire est long, le JS de success.php réduit la taille pour tenir
     dans le conteneur (jamais de débordement horizontal). */
  white-space: nowrap;
}
 
/* Body copy */
.success-body {
  font-family: 'Jost', sans-serif;
  font-size: 14px;
  font-weight: 400;
  color: var(--text-primary);
  line-height: 1.75;
  opacity: 0.88;
  margin-bottom: 28px;
  text-shadow: 0 1px 8px rgba(0,0,0,0.6);
  animation: successFadeUp 0.9s cubic-bezier(0.22,1,0.36,1) 0.15s both;
}
 
/* Transaction reference */
.success-tx {
  font-family: 'Jost', sans-serif;
  font-size: 12.5px;
  font-weight: 300;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  margin-bottom: 36px;
  animation: successFadeUp 0.9s cubic-bezier(0.22,1,0.36,1) 0.25s both;
}
 
.success-tx-ref {
  font-weight: 600;
  color: var(--gold);
  letter-spacing: 0.06em;
}
 
/* Action buttons stack */
.success-actions {
  display: flex;
  flex-direction: column;
  gap: 14px;
  width: 100%;
  max-width: 320px;
  animation: successFadeUp 0.9s cubic-bezier(0.22,1,0.36,1) 0.38s both;
}
 
/* Outlined gold button */
.btn-success-outline {
  display: block;
  width: 100%;
  padding: 15px 24px;
  background: transparent;
  border: 1px solid rgba(201,168,76,0.55);
  border-radius: var(--radius);
  color: var(--text-primary);
  font-family: 'Jost', sans-serif;
  font-size: 13px;
  font-weight: 400;
  letter-spacing: 0.06em;
  text-align: center;
  text-decoration: none;
  cursor: pointer;
  transition:
    background   var(--transition),
    border-color var(--transition),
    color        var(--transition),
    box-shadow   var(--transition);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
}
 
.btn-success-outline:hover {
  background: rgba(201,168,76,0.12);
  border-color: var(--gold);
  color: var(--gold);
  box-shadow: 0 4px 20px rgba(201,168,76,0.18);
}
 
.btn-success-outline:active { opacity: 0.8; }
 
/* Ensure the app grid works for success page
   (main fills the right column fully) */
.success-page .app {
  grid-template-rows: var(--header-h) 1fr auto;
}

/* ═══════════════════════════════════════════
   QUOTE REQUEST PAGE — strict index.php charter
   ═══════════════════════════════════════════ */

/* Flash : une seule ligne, pas de bloc coloré. Or si succès, atténuée sinon. */
.qr-flash {
  font-size: 13px;
  letter-spacing: 0.03em;
  padding: 10px 0;
  margin-bottom: 22px;
  border-bottom: 1px solid var(--border-subtle);
  color: var(--text-muted);
}
.qr-flash.qr-flash-success { color: var(--gold); }
.qr-flash.qr-flash-error   { color: #b56b6b; }

/* Status pill — version sobre (équivalent badge-pill mais variantes neutres) */
.qr-pill {
  display: inline-block;
  font-family: 'Jost', sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 11px;
  border-radius: 20px;
  border: 1px solid var(--border);
  color: var(--text-muted);
  background: transparent;
}
.qr-pill.qr-pill-active {
  background: var(--gold);
  color: #1a1a1a;
  border-color: var(--gold);
}
.qr-pill.qr-pill-warn {
  color: var(--gold);
  border-color: var(--gold);
}

/* ─── Pill cliquable « Réactiver » sur le statut archived/cancelled.
   Indique au survol qu'on peut relancer le devis. */
.qr-pill.qr-pill-revive {
  cursor: pointer;
  font: 500 10.5px/1 'Jost', sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 4px 11px;
  border-radius: 20px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text-muted);
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: color .2s, border-color .2s, background .2s;
}
.qr-pill.qr-pill-revive:hover,
.qr-pill.qr-pill-revive:focus-visible {
  background: rgba(201,168,76,.08);
  border-color: var(--gold);
  color: var(--gold);
  outline: none;
}
.qr-pill-revive-icon {
  display: inline-block;
  font-size: 13px;
  line-height: 1;
  opacity: 0.55;
  transition: opacity .2s, transform .2s;
}
.qr-pill.qr-pill-revive:hover .qr-pill-revive-icon {
  opacity: 1;
  transform: rotate(-90deg);
}

/* Header de section devis : titre + pill alignés horizontalement, ref discrète */
.qr-section-head {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 14px;
  margin-bottom: 20px;
}
.qr-section-head .section-title { margin-bottom: 0; }
.qr-section-head .qr-ref {
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 300;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-muted);
}

/* Note du Maître/admin destinée au client — italic, fine bordure or à gauche */
.qr-admin-note {
  margin: 0 0 22px;
  padding: 12px 0 12px 16px;
  border-left: 2px solid var(--gold);
  font-family: 'Cormorant Garamond', serif;
  font-size: 15px;
  font-style: italic;
  color: var(--text-primary);
  line-height: 1.55;
}

/* Thumbnail cuvée (image bouteille en miniature avant le nom) */
.qr-thumb-cell {
  width: 50px;
  padding-right: 0 !important;
  vertical-align: middle;
}
.qr-thumb {
  display: block;
  height: 38px;
  width: auto;
  max-width: 28px;
  object-fit: contain;
  filter: drop-shadow(0 3px 3px rgba(0,0,0,0.7));
  margin: 0 auto;
}

/* ─── Modale custom de confirmation (remplace confirm() OS) ─────────── */
.qr-modal {
  position: fixed;
  inset: 0;
  z-index: 9000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
}
.qr-modal[hidden] { display: none; }

.qr-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 12, 9, 0.7);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  cursor: pointer;
  animation: qrModalFadeIn 0.18s ease;
}

.qr-modal-dialog {
  position: relative;
  background: var(--bg-card, #303030);
  border: 1px solid var(--border, rgba(201,168,76,0.18));
  border-radius: 8px;
  padding: 28px 32px;
  max-width: 440px;
  width: 100%;
  box-shadow: 0 24px 48px rgba(0, 0, 0, 0.6),
              0 0 0 1px rgba(201, 168, 76, 0.08);
  animation: qrModalSlideIn 0.22s cubic-bezier(0.16, 1, 0.3, 1);
}

.qr-modal-message {
  font-family: 'Cormorant Garamond', serif;
  font-size: 20px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text-primary, #e8e0d0);
  margin: 0 0 24px;
  line-height: 1.4;
}

.qr-modal-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  flex-wrap: wrap;
}
.qr-modal-actions .qr-btn-ghost,
.qr-modal-actions .qr-btn-primary {
  min-width: 110px;
}

@keyframes qrModalFadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}
@keyframes qrModalSlideIn {
  from { opacity: 0; transform: translateY(8px) scale(0.98); }
  to   { opacity: 1; transform: translateY(0) scale(1); }
}

/* Cellule de prix vide pour les lignes neuves (en attente de retarification admin) */
.qr-empty-cell {
  color: var(--text-muted);
  font-style: italic;
  letter-spacing: 0.06em;
}

/* Badge "Nouvelle ligne · à tarifer" sous le nom de cuvée — reprend .qr-tier
   en plus discret (italic + sans uppercase agressif). */
.qr-new-flag {
  text-transform: none !important;
  letter-spacing: 0.02em !important;
  font-style: italic;
  color: var(--text-muted) !important;
}


/* Lien « Rétablir le devis initialement approuvé ↻ » — texte fixe + bouton
   icône inline. Seul le ↻ est cliquable. */
.qr-revert-wrap {
  display: inline-block;
  margin-left: 8px;
  padding-left: 10px;
  border-left: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-style: italic;
}
.qr-revert-btn {
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--gold);
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 3px 7px;
  margin-left: 4px;
  font-family: inherit;
  vertical-align: middle;
  transition: background 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}
.qr-revert-btn:hover {
  background: rgba(201, 168, 76, 0.12);
  border-color: var(--gold);
}
.qr-revert-btn:active {
  background: rgba(201, 168, 76, 0.22);
}

/* Hint dirty : sous les actions, italic sobre */
.qr-dirty-hint {
  margin: 14px 0 0;
  padding: 10px 0 0;
  font-size: 12.5px;
  font-style: italic;
  color: var(--text-muted);
  line-height: 1.55;
  border-top: 1px solid var(--border-subtle);
}

/* Items du devis : on reprend .activity-table mais avec colonnes prix/qty
   alignées à droite. Hover plus discret (pas de cliquabilité, pas de chevron). */
.qr-items-table.activity-table tr.activity-row,
.qr-items-table.activity-table tr:hover { cursor: default; background: transparent; }
.qr-items-table .qr-num { text-align: right; font-variant-numeric: tabular-nums; }
.qr-items-table .qr-cuvee { font-weight: 400; color: var(--text-primary); }
.qr-items-table .qr-tier {
  display: block;
  font-size: 10.5px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--gold);
  margin-top: 2px;
}

/* Quantité inline (input cartons + bouton ↻) */
.qr-qty-form {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.qr-qty-input {
  width: 56px;
  padding: 6px 8px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 13px;
  text-align: center;
  font-variant-numeric: tabular-nums;
  font-family: inherit;
}
.qr-qty-input:focus { border-color: var(--gold); outline: none; }

/* ─── Stepper custom +/- pour les qty inputs du devis ─── */
.qr-qty-stepper {
  display: inline-flex;
  align-items: stretch;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  border-left: 1px solid var(--border-subtle);
  border-right: 1px solid var(--border-subtle);
  border-radius: 4px;
  overflow: hidden;
  background: transparent;
  transition: border-color 0.15s ease;
}
.qr-qty-stepper:focus-within { border-color: var(--gold); }
.qr-qty-stepper:focus-within .qr-qty-stepper-buttons {
  border-left-color: var(--gold);
  border-right-color: var(--gold);
}

/* L'input perd sa propre bordure : c'est le wrapper qui l'apporte. */
.qr-qty-stepper .qr-qty-input {
  border: none !important;
  border-radius: 0;
  width: 44px;
  padding: 6px 6px;
  background: transparent;
  text-align: center;
}
.qr-qty-stepper .qr-qty-input:focus { outline: none; }

/* Hide native spin buttons */
.qr-qty-stepper .qr-qty-input::-webkit-inner-spin-button,
.qr-qty-stepper .qr-qty-input::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.qr-qty-stepper .qr-qty-input { -moz-appearance: textfield; }

.qr-qty-stepper-buttons {
  display: flex;
  flex-direction: column;
  align-items: stretch;                        /* enfants remplissent toute la largeur */
  border-left: 1px solid var(--border-subtle); /* séparateur vertical input ↔ boutons */
  box-sizing: border-box;
  position: relative;                          /* support la ligne ::after centrée */
  transition: border-left-color 0.12s ease, border-right-color 0.12s ease;
}

.qr-qty-stepper .qr-qty-stepper-buttons:hover {
  border-left-color: rgba(201,168,76,0.12);
  border-right-color: rgba(201,168,76,0.12);
}
.qr-qty-stepper .qr-qty-stepper-buttons:active {
  border-left-color: rgba(201,168,76,0.22);
  border-right-color: rgba(201,168,76,0.22);
}

.qr-qty-stepper-buttons::after {
  content: '';
  position: absolute;
  left: 0;
  right: 0;
  top: 50%;
  height: 1px;
  background: var(--border-subtle);
  pointer-events: none;
}
.qr-qty-step {
  flex: 1 1 0;             /* SPLIT 50/50 de la hauteur disponible */
  min-height: 0;           /* autorise le shrink pour que flex:1 s'applique vraiment */
  width: calc(100% + 1px);
  margin: 0;
  outline: none;
  appearance: none;
  -webkit-appearance: none;
  background: transparent;
  border: none;
  box-sizing: border-box;
  color: var(--gold);
  cursor: pointer;
  /* padding-bottom 3px (vs top 0) → contenu centré flex remonte de 1px */
  padding: 0 8px 3px 8px;
  font-size: 13px;         /* glyphe + / − un peu plus lisible */
  line-height: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: 'Jost', sans-serif;
  font-weight: 500;
  transition: background 0.12s ease, color 0.12s ease;
}
.qr-qty-step:hover  { background: rgba(201,168,76,0.12); }
.qr-qty-step:active { background: rgba(201,168,76,0.22); }

/* Boutons utilitaires (↻ recalc, × supprimer) — tout en text-muted, hover or */
.qr-icon-btn {
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 14px;
  cursor: pointer;
  padding: 4px 6px;
  line-height: 1;
  border-radius: 4px;
  transition: color 0.15s ease, background 0.15s ease;
}
.qr-icon-btn:hover { color: var(--gold); }
.qr-icon-btn-danger:hover { color: #b56b6b; }

/* Totaux : liste compacte, alignée à droite, séparée par border-subtle */
.qr-totals {
  display: flex;
  justify-content: flex-end;
  margin-top: 18px;
}
.qr-totals dl {
  margin: 0;
  display: grid;
  grid-template-columns: auto auto;
  gap: 8px 24px;
  font-size: 13.5px;
  font-weight: 300;
}
.qr-totals dt { color: var(--text-muted); }
.qr-totals dd { margin: 0; text-align: right; font-variant-numeric: tabular-nums; color: var(--text-primary); }
.qr-totals .qr-totals-grand dt,
.qr-totals .qr-totals-grand dd {
  padding-top: 10px;
  border-top: 1px solid var(--border-subtle);
  color: var(--gold);
  font-weight: 500;
  font-size: 16px;
  letter-spacing: 0.02em;
}

/* Méta livraison : ligne unique, intercalée entre items et actions */
.qr-meta-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px;
  padding: 16px 0;
  font-size: 12.5px;
  letter-spacing: 0.05em;
  color: var(--text-muted);
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin: 22px 0;
}
.qr-meta-row .qr-meta-label {
  text-transform: uppercase;
  font-size: 10.5px;
  letter-spacing: 0.14em;
  margin-right: 6px;
}
.qr-meta-row strong { color: var(--text-primary); font-weight: 400; }

/* Actions devis : 3 boutons espacés, pas de bloc coloré */
.qr-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
  justify-content: flex-end;
}
.qr-actions .qr-action-spacer { flex: 1; }

/* Bouton primaire devis = btn-add full-width adapté en inline */
.qr-btn-primary {
  background: transparent;
  border: 1px solid var(--gold);
  color: var(--gold);
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 10px 22px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: background 0.18s ease, color 0.18s ease;
}
.qr-btn-primary:hover { background: var(--gold); color: #1a1a1a; }

/* Bouton secondaire = ghost text-muted, underline au hover */
.qr-btn-ghost {
  background: transparent;
  border: 1px solid var(--border-subtle);
  color: var(--text-muted);
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  padding: 10px 18px;
  border-radius: var(--radius);
  cursor: pointer;
  transition: color 0.15s ease, border-color 0.15s ease;
}
.qr-btn-ghost:hover { color: var(--gold); border-color: var(--gold); }

/* Lien-bouton (« Ajouter une adresse ») — pas de bordure, juste underline */
.qr-link {
  background: transparent;
  border: none;
  color: var(--gold);
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: underline;
  cursor: pointer;
  padding: 0;
}
.qr-link:hover { color: var(--gold-light); }

/* Status banner (submitted / revision_requested) — discret, juste une ligne */
.qr-status-banner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  padding: 16px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin-bottom: 32px;
}
.qr-status-banner .qr-status-text {
  flex: 1 1 320px;
  font-size: 13px;
  color: var(--text-muted);
  line-height: 1.6;
}
.qr-status-banner .qr-status-text strong {
  color: var(--text-primary);
  font-family: 'Cormorant Garamond', serif;
  font-size: 18px;
  font-weight: 500;
  display: block;
  margin-bottom: 4px;
}

/* Builder form (add cuvée) */
.qr-add-summary {
  list-style: none;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--gold);
  padding: 10px 0;
}
.qr-add-summary::-webkit-details-marker { display: none; }
.qr-add-details[open] .qr-add-summary { margin-bottom: 14px; }

.qr-add-form {
  display: grid;
  grid-template-columns: 2fr 1.2fr 1fr 1fr auto;
  gap: 12px;
  align-items: end;
  padding: 16px 0;
  border-top: 1px solid var(--border-subtle);
}
.qr-add-form label {
  display: block;
  font-family: 'Jost', sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 6px;
}
.qr-add-form select,
.qr-add-form input[type=number] {
  width: 100%;
  padding: 9px 10px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
}
.qr-add-form select:focus,
.qr-add-form input[type=number]:focus {
  border-color: var(--gold);
  outline: none;
}

/* Popup d'options des selects : OS rend la liste avec sa propre surface
   (généralement blanche), donc on force un texte sombre + fond blanc pour
   garantir la lisibilité (sinon : texte clair sur fond clair = invisible). */
.qr-add-form select option {
  color: #111;
  background: #fff;
}

/* Variant --block du stepper : occupe toute la largeur de la cellule de
   grille du form d'ajout, l'input prend l'espace restant à gauche, la
   colonne +/- vient se coller à droite. */
.qr-qty-stepper--block {
  display: flex;
  width: 100%;
}
.qr-qty-stepper--block .qr-qty-input,
.qr-qty-stepper--block input[type=number] {
  flex: 1;
  width: auto;
  border: none !important;
  border-radius: 0;
  background: transparent;
  padding: 9px 10px;
  text-align: center;
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
}
.qr-qty-stepper--block input[type=number]::-webkit-inner-spin-button,
.qr-qty-stepper--block input[type=number]::-webkit-outer-spin-button {
  -webkit-appearance: none;
  margin: 0;
}
.qr-qty-stepper--block input[type=number] { -moz-appearance: textfield; }
.qr-add-preview {
  font-size: 11.5px;
  color: var(--text-muted);
  font-style: italic;
  padding: 6px 0 0;
  letter-spacing: 0.02em;
}
@media (max-width: 720px) {
  .qr-add-form { grid-template-columns: 1fr 1fr; }
}

/* Options globales (mode livraison + pays) */
.qr-options-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 24px;
  padding: 18px 0;
  border-top: 1px solid var(--border-subtle);
  border-bottom: 1px solid var(--border-subtle);
  margin: 22px 0;
}
.qr-options-row .qr-option-label {
  display: block;
  font-family: 'Jost', sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.qr-mode-toggle {
  display: flex;
  gap: 0;
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  overflow: hidden;
}
.qr-mode-toggle button {
  flex: 1;
  background: transparent;
  border: none;
  padding: 10px 14px;
  font-family: 'Jost', sans-serif;
  font-size: 11px;
  font-weight: 400;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--text-muted);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}
.qr-mode-toggle button + button { border-left: 1px solid var(--border-subtle); }
.qr-mode-toggle button:hover { color: var(--text-primary); }
.qr-mode-toggle button.is-active {
  background: var(--gold);
  color: #1a1a1a;
  font-weight: 500;
}
.qr-country-input {
  width: 90px;
  padding: 9px 10px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-family: inherit;
}
.qr-country-input:focus { border-color: var(--gold); outline: none; }

/* Select pays — nom complet, style cohérent avec qr-add-form select */
.qr-country-select {
  min-width: 200px;
  padding: 9px 28px 9px 10px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
  letter-spacing: 0.02em;
  cursor: pointer;
}
.qr-country-select:focus { border-color: var(--gold); outline: none; }
.qr-country-select option { color: #111; }

/* Submit form (message + bouton envoi) */
.qr-submit-form {
  padding-top: 22px;
  border-top: 1px solid var(--border-subtle);
}
.qr-submit-form label {
  display: block;
  font-family: 'Jost', sans-serif;
  font-size: 10.5px;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 8px;
}
.qr-submit-form textarea {
  width: 100%;
  padding: 12px 14px;
  background: transparent;
  border: 1px solid var(--border-subtle);
  border-radius: 4px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 13.5px;
  line-height: 1.5;
  resize: vertical;
  min-height: 86px;
}
.qr-submit-form textarea:focus { border-color: var(--gold); outline: none; }
.qr-submit-form .qr-submit-row {
  display: flex;
  justify-content: flex-end;
  margin-top: 16px;
}

/* Empty-state utilitaire */
.qr-empty {
  text-align: center;
  padding: 40px 16px;
  color: var(--text-muted);
  font-style: italic;
  font-size: 13.5px;
}

/* Notice « adresse manquante » : juste un texte gold, pas de cube rouge */
.qr-address-notice {
  flex: 1 1 280px;
  font-size: 12.5px;
  color: var(--text-muted);
  line-height: 1.6;
}
.qr-address-notice strong { color: var(--gold); font-weight: 500; }

/* Section header info en haut de page */
.qr-page-header { margin-bottom: 30px; }
.qr-page-header .qr-page-title {
  font-family: 'Cormorant Garamond', serif;
  font-size: 28px;
  font-weight: 500;
  letter-spacing: 0.02em;
  color: var(--text-primary);
  margin: 0 0 6px;
}
.qr-page-header .qr-page-sub {
  font-size: 13px;
  color: var(--text-muted);
  font-weight: 300;
  margin: 0;
}
