/* web/account/css/style.css */

/* ── Police servie par le domaine, et non par Google ──
   Le chargement depuis fonts.googleapis.com envoyait l'adresse IP de chaque visiteur
   à Google LLC, absent des cinq sous-traitants déclarés dans confidentialite.html.
   C'est ici que ça comptait le plus : le portail est vu par les **clients connectés**,
   pas par des curieux de passage. Fichier variable 300→700, licence OFL, copié dans
   le dépôt le 2026-08-04. Chemin absolu depuis la racine du site — cette feuille est
   servie depuis /account/, la police vit dans /assets/.
   Voir le commentaire détaillé en tête de web/index.html. */
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('/assets/fonts/space-grotesk-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Space Grotesk';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('/assets/fonts/space-grotesk-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  /* Palette « sombre aéré » (refonte du 2026-09-27, spec
     docs/superpowers/specs/2026-09-27-refonte-portail-client-design.md § 1).
     On garde l'identité noire de l'app, mais plus contrastée : le fond n'est
     plus un noir pur, les cartes s'en détachent, le texte secondaire passe
     l'AA partout où il porte de l'information. */
  --bg: #111113;
  /* Menu latéral : un cran plus sombre que le fond, pour qu'il se lise comme
     un cadre et non comme une colonne de contenu. */
  --sidebar: #0a0a0b;
  --surface: #1c1c1f;
  --surface2: #26262a;
  --border: #2a2a2e;
  --accent: #F5AB00;
  /* #3B7DF5 jusqu'au 2026-09-27 : 4,40:1 sur les cartes, sous l'AA pour un lien
     de 13 px. Éclairci sans changer de teinte. */
  --blue: #6ea0ff;
  --text: #F0EDE8;
  /* #555 jusqu'au 2026-08-23, puis #8C8781 : 4,77:1 sur l'ancienne surface.
     #9a968f donne 5,77:1 sur les cartes (#1c1c1f) et 6,41:1 sur le fond. */
  --muted: #9a968f;
  /* Ce qui n'a pas commencé ou n'ira nulle part : présent, mais éteint. */
  --inert: #4A4744;
  --error: #ff5757;
  --success: #5fd07f;
  /* Fonds des pastilles de statut : vert « arrivé », jaune « en cours ». */
  --success-bg: #16351f;
  --accent-bg: #3a2e0a;
  --radius: 12px;
  /* Hauteur de la barre haute sous 900 px : sert aux éléments collants
     (colonne de « Mon compte ») pour ne pas passer dessous. */
  --topbar-h: 104px;
}

html, body { min-height: 100%; min-height: 100dvh; }
body {
  font-family: 'Space Grotesk', -apple-system, BlinkMacSystemFont, 'SF Pro Display', 'Segoe UI', sans-serif;
  background: var(--bg);
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

/* ── Login ── */
#login-screen { display: flex; align-items: center; justify-content: center; min-height: 100vh; padding: 24px 20px; }
.login-box { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px 24px; width: 100%; max-width: 380px; }
.logo { font-family: 'Space Grotesk', -apple-system, sans-serif; font-style: normal; font-size: 0.95rem; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); text-align: center; margin-bottom: 24px; display: flex; align-items: center; justify-content: center; gap: 0.7rem; }
.logo-icon { display: block; height: 32px; width: 32px; border-radius: 8px; flex-shrink: 0; }
/* Login box: icon stacked above text, larger */
.login-box .logo { flex-direction: column; gap: 12px; margin-bottom: 24px; }
.login-box .logo-icon { height: 64px; width: 64px; border-radius: 16px; }
.login-box h1 { font-size: 20px; margin-bottom: 4px; }
.login-box p { color: var(--muted); font-size: 13px; margin-bottom: 20px; }
.form-label { display: block; font-size: 11px; color: var(--muted); margin-bottom: 6px; text-transform: uppercase; letter-spacing: .5px; }
.form-input { width: 100%; padding: 11px 14px; background: var(--bg); border: 1px solid var(--border); border-radius: 8px; color: var(--text); font-size: 14px; margin-bottom: 14px; outline: none; }
.form-input:focus { border-color: var(--accent); }
/* Œil afficher/masquer d'un champ mot de passe (utils.js, attachPasswordToggle). */
.pw-field { position: relative; margin-bottom: 14px; }
.pw-field .form-input { margin-bottom: 0; padding-right: 46px; }
.pw-toggle { position: absolute; top: 0; right: 0; height: 100%; width: 44px; display: grid; place-items: center; background: none; border: none; color: var(--muted); cursor: pointer; padding: 0; }
.pw-toggle:hover, .pw-toggle:focus-visible { color: var(--text); }
/* Téléphone : menu d'indicatif à gauche, à sa largeur, le numéro prend le reste. */
.phone-input { display: flex; gap: 8px; }
.phone-input select.form-input { width: auto; flex: 0 0 auto; max-width: 45%; }
.phone-input input.form-input { flex: 1; min-width: 0; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 1px solid var(--border); background: var(--surface2); color: var(--text); border-radius: 10px; padding: 11px 16px; font-size: 14px; cursor: pointer; font-weight: 600; text-decoration: none; }
.btn-primary { background: var(--accent); color: #111; border-color: var(--accent); }
.btn:not(.btn-primary):not(.btn-apple):not(.btn-google):not(.btn-danger):hover { border-color: #3a3a40; }
.btn-block { width: 100%; }
.btn-apple { background: #000; color: #fff; border-color: #333; }
.btn-google { background: #fff; color: #1f1f1f; border-color: #dadce0; display: flex; align-items: center; justify-content: center; gap: 10px; margin-top: 10px; }
.btn-google .google-g { flex: none; }
.btn-sm { padding: 7px 12px; font-size: 12px; }
.link { color: var(--blue); font-size: 13px; cursor: pointer; text-decoration: none; background: none; border: none; padding: 0; }
.error-msg { color: var(--error); font-size: 13px; margin-top: 10px; display: none; }
.success-msg { color: var(--success); font-size: 13px; margin-top: 10px; display: none; }
.divider { display: flex; align-items: center; gap: 10px; margin: 18px 0; color: var(--muted); font-size: 12px; }
.divider::before, .divider::after { content: ''; flex: 1; height: 1px; background: var(--border); }

/* ── App shell ── */
/* Menu latéral (≥ 900 px) + contenu jusqu'à ~1100 px. L'ancien en-tête
   horizontal centrait tout dans une colonne de 720 px : sur un écran
   d'ordinateur, les deux tiers de la page restaient vides. Sous 900 px le menu
   redevient une barre compacte en haut, entrées défilables horizontalement.
   `#app-screen` garde son `display: block` posé par nav.js (`showApp`) : c'est
   `.app-shell`, à l'intérieur, qui porte la grille. */
#app-screen { display: none; min-height: 100vh; }
.app-shell { display: grid; grid-template-columns: 232px minmax(0, 1fr); min-height: 100vh; min-height: 100dvh; }
.sidebar {
  position: sticky; top: 0; height: 100vh; height: 100dvh;
  background: var(--sidebar); border-right: 1px solid #222;
  display: flex; flex-direction: column; gap: 4px;
  padding: 24px 16px 20px;
  z-index: 10;
}
.sidebar .logo { margin: 0 0 22px 8px; justify-content: flex-start; text-align: left; font-size: 0.9rem; }
.sidebar .logo-icon { height: 28px; width: 28px; }
.side-nav { display: flex; flex-direction: column; gap: 4px; }
.nav-link {
  display: block; padding: 10px 12px; border-radius: 10px;
  color: var(--muted); text-decoration: none; font-size: 14px; font-weight: 500;
  white-space: nowrap; transition: color .15s, background .15s;
}
.nav-link:hover { color: var(--text); background: var(--surface); }
.nav-link[aria-current="page"] { background: var(--accent); color: #111; font-weight: 600; }
.side-foot {
  margin-top: auto; padding-top: 16px; border-top: 1px solid var(--border);
  display: flex; flex-direction: column; gap: 12px;
}
.side-user { display: flex; align-items: center; gap: 10px; }
.side-user .btn { flex: 1; }
.acct-avatar { width: 32px; height: 32px; border-radius: 50%; background: transparent; border: 1.5px solid var(--accent); color: var(--accent); font-size: 11px; font-weight: 700; letter-spacing: 0; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; flex-shrink: 0; transition: background .15s, transform .1s; font-family: -apple-system, BlinkMacSystemFont, 'Space Grotesk', sans-serif; }
.acct-avatar:hover { background: rgba(245,171,0,.12); transform: scale(1.08); }
.lang-select { background: var(--surface2); border: 1px solid var(--border); color: var(--text); border-radius: 8px; padding: 6px 8px; font-size: 12px; align-self: flex-start; }
.app-main { min-width: 0; display: flex; flex-direction: column; }
.main-content { width: 100%; max-width: 1100px; margin: 0 auto; padding: 40px 40px 24px; }

@media (max-width: 899px) {
  .app-shell { display: block; }
  .sidebar {
    height: auto; min-height: var(--topbar-h);
    flex-direction: row; flex-wrap: wrap; align-items: center;
    gap: 8px 10px; padding: 10px 16px 0;
    border-right: 0; border-bottom: 1px solid var(--border);
  }
  .sidebar .logo { margin: 0; flex: 1 1 auto; min-width: 0; }
  .side-foot { order: 2; margin: 0; padding: 0; border: 0; flex-direction: row; align-items: center; gap: 8px; }
  .lang-select { align-self: center; }
  .side-nav {
    order: 3; width: 100%; flex-direction: row; gap: 4px;
    overflow-x: auto; scrollbar-width: none; padding-bottom: 10px;
  }
  .side-nav::-webkit-scrollbar { display: none; }
  .nav-link { padding: 7px 12px; font-size: 13.5px; }
  .main-content { padding: 24px 16px; }
}
/* Téléphone étroit : le nom à côté du logo passe à la ligne avant les boutons. */
@media (max-width: 420px) {
  .sidebar .logo { font-size: 0.8rem; letter-spacing: .08em; gap: .5rem; }
  .sidebar .logo-icon { height: 24px; width: 24px; }
}

/* ── Cards & lists ── */
.section-title { font-size: 13px; text-transform: uppercase; letter-spacing: .8px; color: var(--muted); margin: 24px 0 10px; }
.section-title:first-child { margin-top: 0; }
.card-list { display: flex; flex-direction: column; gap: 10px; }
.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 16px; cursor: pointer; }
.card:not(.no-click):hover { border-color: var(--accent); }
.card-title { font-size: 15px; font-weight: 600; margin-bottom: 4px; }
.card-meta { font-size: 12px; color: var(--muted); display: flex; gap: 10px; flex-wrap: wrap; align-items: center; }
.badge { display: inline-block; padding: 2px 8px; border-radius: 6px; font-size: 11px; font-weight: 600; }
.badge-active, .badge-live { background: rgba(76,175,80,.15); color: var(--success); }
.badge-closed, .badge-completed { background: rgba(138,138,138,.2); color: var(--muted); }
.badge-archived { background: rgba(138,138,138,.15); color: var(--muted); }
.badge-pending, .badge-processing, .badge-printing { background: rgba(245,171,0,.15); color: var(--accent); }
.badge-cancelled { background: rgba(138,138,138,.2); color: var(--muted); }
.empty-state, .loading-state { text-align: center; color: var(--muted); font-size: 13px; padding: 32px 0; }
.error-state { text-align: center; color: var(--error); font-size: 13px; padding: 24px 0 8px; }

/* ── Fiches : lien retour ──
   Les onglets des fiches (`.tabs`, `.tab`, `.tab-content`) ont disparu avec la
   refonte du 2026-09-27 : voir « Fiches pellicule et événement » plus bas. */
.back-link { display: inline-flex; align-items: center; gap: 6px; color: var(--muted); font-size: 13px; text-decoration: none; margin-bottom: 12px; }
.back-link:hover { color: var(--text); }

/* ── Toast ── */
.toast { position: fixed; bottom: 20px; right: 20px; background: var(--surface2); border: 1px solid var(--border); color: var(--text); padding: 10px 16px; border-radius: 8px; font-size: 13px; z-index: 9999; max-width: 320px; }
.toast.error { border-color: var(--error); color: var(--error); }

/* ── Event stats ── */
.stats { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px,1fr)); gap: 10px; margin-bottom: 20px; }
.stat { background: var(--surface); border: 1px solid var(--border); border-radius: 10px; padding: 14px 16px; }
.stat-label { font-size: 10px; color: var(--muted); text-transform: uppercase; letter-spacing: .5px; margin-bottom: 6px; }
.stat-value { font-size: 22px; font-weight: 700; }
.participant-row { display: flex; justify-content: space-between; font-size: 13px; padding: 8px 0; border-bottom: 1px solid var(--border); }
.participant-row:last-child { border-bottom: none; }
.qr-box { display: flex; flex-direction: column; align-items: center; gap: 12px; padding: 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 16px; }
.qr-box svg { width: 160px; height: 160px; }
.copy-link-row { display: flex; gap: 8px; width: 100%; max-width: 320px; }
.copy-link-row input { flex: 1; margin-bottom: 0; }
.banner-closed { background: var(--surface2); border: 1px solid var(--border); border-radius: 10px; padding: 10px 14px; font-size: 13px; color: var(--muted); margin-bottom: 16px; text-align: center; }

/* ── Gallery tab ── */
.gallery-toolbar { display: flex; justify-content: flex-end; margin-bottom: 14px; }
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
  gap: 6px;
}
.gallery-thumb {
  aspect-ratio: 1;
  overflow: hidden;
  border-radius: 8px;
  background: var(--surface2);
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color .15s;
}
.gallery-thumb:hover { border-color: var(--accent); }
.gallery-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gallery-deleted { text-align: center; color: var(--muted); font-size: 13px; padding: 32px 16px; }
.gallery-deleted a { color: var(--blue); }

/* ── Lightbox ── */
.lightbox-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.92);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
}
.lightbox-img { max-width: 90vw; max-height: 90vh; object-fit: contain; border-radius: 8px; }
.lightbox-close {
  position: absolute; top: 16px; right: 20px;
  font-size: 28px; color: var(--muted); cursor: pointer; background: none; border: none; line-height: 1;
}
.lightbox-close:hover { color: var(--text); }
.lightbox-nav {
  position: absolute; top: 50%; transform: translateY(-50%);
  background: rgba(255,255,255,.1); border: none; color: var(--text);
  font-size: 24px; padding: 12px 16px; cursor: pointer; border-radius: 8px;
}
.lightbox-nav:hover { background: rgba(255,255,255,.2); }
.lightbox-nav.prev { left: 12px; }
.lightbox-nav.next { right: 12px; }
.lightbox-counter { position: absolute; bottom: 16px; left: 50%; transform: translateX(-50%); color: var(--muted); font-size: 12px; }

/* ── Reprints tab ── */
/* Reprints stepper */
.reprints-stepper { display: flex; align-items: flex-start; margin-bottom: 28px; }
.reprints-step { display: flex; flex-direction: column; align-items: center; gap: 6px; flex-shrink: 0; min-width: 60px; }
.reprints-step__circle { width: 28px; height: 28px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; border: 2px solid var(--border); color: var(--muted); background: var(--surface); flex-shrink: 0; }
.reprints-step__label { font-size: 10px; color: var(--muted); text-align: center; line-height: 1.3; max-width: 64px; }
.reprints-step__hint { font-size: 9px; color: var(--accent); text-align: center; max-width: 64px; }
.reprints-step__line { flex: 1; height: 2px; background: var(--border); margin-top: 13px; }
.reprints-step--done .reprints-step__circle { background: var(--accent); border-color: var(--accent); color: #1a1100; }
.reprints-step--done .reprints-step__label { color: var(--text); }
.reprints-step--active .reprints-step__circle { border-color: var(--accent); color: var(--accent); background: var(--surface2); }
.reprints-step--active .reprints-step__label { color: var(--text); font-weight: 600; }
.reprints-step__line--done { background: var(--accent); }
.reprints-lock-banner { font-size: 13px; color: var(--accent); padding: 12px 16px; background: rgba(245,171,0,.08); border: 1px solid rgba(245,171,0,.2); border-radius: 10px; margin-bottom: 20px; line-height: 1.5; }
.format-desc { font-size: 12px; color: var(--muted); margin-top: 6px; line-height: 1.5; }
.reprints-section { margin-bottom: 28px; }
.reprints-section-title { font-size: 11px; text-transform: uppercase; letter-spacing: .8px; color: var(--muted); margin-bottom: 12px; }
.reprints-deleted-banner { text-align: center; color: var(--muted); font-size: 13px; padding: 24px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin-bottom: 20px; }
.reprints-select-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.reprints-select-bar-btns { display: flex; gap: 8px; }
.reprints-selected-count { font-size: 12px; color: var(--muted); }
.reprints-photo-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(90px, 1fr));
  gap: 6px;
  margin-bottom: 16px;
}
.reprints-photo-item {
  position: relative;
  aspect-ratio: 1;
  border-radius: 8px;
  overflow: hidden;
  background: var(--surface2);
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color .15s;
  user-select: none;
}
.reprints-photo-item:hover { border-color: var(--muted); }
.reprints-photo-item.selected { border-color: var(--accent); }
.reprints-photo-item img { width: 100%; height: 100%; object-fit: cover; display: block; pointer-events: none; }
.reprints-photo-check {
  position: absolute; top: 5px; right: 5px;
  width: 20px; height: 20px;
  border: 2px solid rgba(255,255,255,.6);
  border-radius: 4px;
  background: rgba(0,0,0,.35);
  display: flex; align-items: center; justify-content: center;
  font-size: 11px; font-weight: 700;
  color: transparent;
}
.reprints-photo-item.selected .reprints-photo-check {
  background: var(--accent);
  border-color: var(--accent);
  color: #1a1100;
}
.reprints-photo-cover {
  position: absolute; top: 5px; left: 5px;
  width: 22px; height: 22px;
  border: 0; border-radius: 4px;
  background: rgba(0,0,0,.45);
  color: rgba(255,255,255,.75);
  font-size: 12px; line-height: 1;
  display: none; align-items: center; justify-content: center;
  cursor: pointer;
}
/* Le bouton couverture n'a de sens que pour un album, et que sur une photo commandée. */
.reprints-photo-grid.is-album .reprints-photo-item.selected .reprints-photo-cover { display: flex; }
.reprints-photo-item.is-cover .reprints-photo-cover { background: var(--accent); color: #1a1100; }
.reprints-photo-item.is-cover { border-color: var(--accent); box-shadow: inset 0 0 0 2px var(--accent); }
.reprints-hint { color: var(--muted); font-size: 12px; margin: 4px 0 0; }

.reprints-form-row { margin-bottom: 14px; }
/* `hidden` doit gagner même si `.reprints-form-row` reçoit un jour un `display`. */
.reprints-form-row[hidden] { display: none; }
.reprints-form-row .form-label { margin-bottom: 6px; }
.reprints-price-recap {
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 16px;
}
.reprints-price-label { font-size: 13px; color: var(--muted); }
.reprints-price-value { font-size: 22px; font-weight: 700; color: var(--accent); }
.reprints-payment-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.88);
  z-index: 1000;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.reprints-payment-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  width: 100%;
  max-width: 420px;
}
.reprints-payment-box h2 { font-size: 16px; font-weight: 700; margin-bottom: 20px; }
.reprints-orders-table { width: 100%; border-collapse: collapse; font-size: 13px; }
.reprints-orders-table th {
  text-align: left;
  font-size: 10px; text-transform: uppercase; letter-spacing: .5px;
  color: var(--muted); padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}
.reprints-orders-table td { padding: 10px 4px; border-bottom: 1px solid var(--border); vertical-align: middle; }
.reprints-orders-table td:first-child { padding-left: 0; }
.reprints-orders-table tr:last-child td { border-bottom: none; }
.badge-shipped { background: rgba(77,157,224,.15); color: var(--blue); }
.badge-delivered { background: rgba(76,175,80,.15); color: var(--success); }
.badge-awaiting_payment { background: rgba(138,138,138,.2); color: var(--muted); }
.badge-succeeded { background: rgba(76,175,80,.15); color: var(--success); }

/* ── Footer ── */
/* Largeur alignée sur `.main-content` : le pied de page suit le contenu, pas
   l'ancienne colonne de 720 px. `margin-top: auto` le colle en bas d'une page
   courte (la colonne `.app-main` est en flex vertical). */
.footer { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 20px; padding: 20px 40px; border-top: 1px solid var(--border); font-size: 12px; color: var(--muted); width: 100%; max-width: 1100px; margin: auto auto 0; }
@media (max-width: 899px) { .footer { padding: 20px 16px; margin-top: 40px; } }
.footer-link { color: var(--muted); text-decoration: none; transition: color .15s; }
.footer-link:hover { color: var(--text); }
#login-footer { position: fixed; bottom: 0; left: 0; right: 0; margin: 0; max-width: none; justify-content: center; border-top: 1px solid var(--border); }

/* ── Account settings — layout ── */
.acct-layout {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 28px;
  align-items: start;
  padding-top: 24px;
}
@media (max-width: 680px) {
  .acct-layout { grid-template-columns: 1fr; gap: 0; padding-top: 0; }
}

.acct-sidebar {
  position: sticky;
  /* 76 px = l'ancien en-tête collant. Le menu est désormais sur le côté
     (≥ 900 px), ou dans une barre haute collante de `--topbar-h` en dessous. */
  top: 24px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}
@media (max-width: 899px) {
  .acct-sidebar { top: calc(var(--topbar-h) + 16px); }
}
@media (max-width: 680px) {
  .acct-sidebar { position: static; }
}

.acct-hero {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 14px;
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 12px;
}
@media (max-width: 680px) {
  .acct-hero {
    flex-direction: row;
    text-align: left;
    border-radius: 0;
    border-left: none;
    border-right: none;
    border-top: none;
    padding: 14px 20px;
    background: transparent;
    gap: 14px;
  }
}

.acct-avatar-lg {
  width: 60px; height: 60px;
  border-radius: 50%;
  background: rgba(245,171,0,.08);
  border: 2px solid var(--accent);
  color: var(--accent);
  font-family: -apple-system, BlinkMacSystemFont, 'SF Pro Display', sans-serif;
  font-size: 18px; font-weight: 800; font-style: normal;
  display: flex; align-items: center; justify-content: center; flex-shrink: 0;
  box-shadow: 0 0 0 6px rgba(245,171,0,.05);
  letter-spacing: 1px;
}
@media (max-width: 680px) {
  .acct-avatar-lg { width: 44px; height: 44px; font-size: 14px; box-shadow: none; }
}

.acct-hero-info { min-width: 0; }
.acct-hero-email { font-size: 13px; font-weight: 600; word-break: break-all; margin-bottom: 3px; }
.acct-hero-since { font-size: 11px; color: var(--muted); }

.acct-nav {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 6px;
  display: flex;
  flex-direction: column;
  gap: 2px;
}
@media (max-width: 680px) {
  .acct-nav {
    border-radius: 0;
    border-left: none; border-right: none; border-top: none;
    background: transparent;
    padding: 0;
    flex-direction: row;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    gap: 0;
  }
}

.acct-nav-item {
  display: block;
  padding: 9px 12px;
  font-size: 13px;
  font-weight: 500;
  color: var(--muted);
  text-decoration: none;
  border-radius: 8px;
  border: none;
  background: transparent;
  cursor: pointer;
  white-space: nowrap;
  transition: color .15s, background .15s;
  text-align: left;
}
.acct-nav-item:hover { color: var(--text); background: var(--surface2); }
.acct-nav-item.active { color: var(--accent); background: rgba(245,171,0,.08); font-weight: 600; }
@media (max-width: 680px) {
  .acct-nav-item {
    border-radius: 0;
    padding: 10px 16px;
    border-bottom: 2px solid transparent;
    flex-shrink: 0;
  }
  .acct-nav-item:hover { background: transparent; }
  .acct-nav-item.active { background: transparent; border-bottom-color: var(--accent); }
}

.acct-content { display: flex; flex-direction: column; min-width: 0; }
@media (max-width: 680px) {
  .acct-content { padding: 16px 0 0; }
}

.acct-section-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 24px 24px 28px;
}
@media (max-width: 680px) {
  .acct-section-card { border-radius: 12px; padding: 20px 16px; }
}

.acct-section-title {
  font-family: 'Space Grotesk', -apple-system, sans-serif;
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
  letter-spacing: -.2px;
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}

.acct-form { max-width: none; }
.acct-form-actions { margin-top: 20px; display: flex; gap: 10px; flex-wrap: wrap; }
.acct-form-row-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.acct-form-row-zip-city { display: grid; grid-template-columns: 1fr 2fr; gap: 12px; }

.btn-danger { background: transparent; color: var(--error); border-color: rgba(255,87,87,.4); }
.btn-danger:hover { background: rgba(255,87,87,.08); border-color: var(--error); }

.acct-delete-desc { font-size: 13px; color: var(--muted); margin-bottom: 20px; line-height: 1.6; }
.acct-delete-confirm { background: rgba(255,87,87,.04); border: 1px solid rgba(255,87,87,.18); border-radius: 10px; padding: 16px; margin-top: 16px; }
.acct-delete-confirm-label { font-size: 13px; color: var(--muted); margin-bottom: 10px; }
.acct-section--danger .acct-section-title { color: var(--error); opacity: .85; border-bottom-color: rgba(255,87,87,.2); }

.acct-orders-scroll { overflow-x: auto; -webkit-overflow-scrolling: touch; }

/* ── Film rolls (solo) ── */
.acct-rolls-list { display: flex; flex-direction: column; gap: 10px; }
.acct-roll-card { background: var(--surface2); border: 1px solid var(--border); border-radius: 10px; padding: 12px 16px; }
.acct-roll-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 6px; }
.acct-roll-name { font-size: 14px; font-weight: 600; }
.acct-roll-meta { display: flex; gap: 14px; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
.acct-roll-delivery { display: flex; align-items: center; gap: 8px; padding-top: 8px; margin-top: 8px; border-top: 1px solid var(--border); font-size: 12px; }
.acct-roll-delivery-label { color: var(--muted); }
.acct-roll-delivery-num { color: var(--muted); font-family: monospace; font-size: 11px; }
.badge-submitted { background: rgba(245,171,0,.15); color: var(--accent); }
.badge-test_mode { background: rgba(138,138,138,.2); color: var(--muted); }
.badge-completed { background: rgba(76,175,80,.15); color: var(--success); }
.acct-back-btn { display: block; width: 100%; padding: 9px 12px; font-size: 12px; color: var(--muted); background: transparent; border: none; border-radius: 8px; cursor: pointer; text-align: left; transition: color .15s, background .15s; }
.acct-back-btn:hover { color: var(--text); background: var(--surface2); }
@media (max-width: 680px) { .acct-back-btn { display: none; } }

/* ── Avertissement d'expiration de session ── */
/* z-index au-dessus de la visionneuse (1000) et du paiement des réimpressions
   (1000) : l'avertissement doit rester lisible même une photo ouverte en grand,
   sinon il expire derrière l'écran noir sans que personne le voie. */
.session-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.88);
  z-index: 1100;
  display: flex; align-items: center; justify-content: center;
  padding: 20px;
}
.session-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px 24px;
  width: 100%;
  max-width: 400px;
}
.session-box h2 { font-size: 17px; font-weight: 700; margin-bottom: 8px; }
.session-text { font-size: 13px; color: var(--muted); line-height: 1.5; }
.session-actions { display: flex; gap: 10px; margin-top: 20px; }
.session-actions .btn { flex: 1; }

/* ── Le fil unique ──────────────────────────────────────────────────────── */
/* Remplace les deux listes « Mes événements » / « Mes pellicules ». Les
   anciennes classes .card / .card-list restent en place : elles servent encore
   dans les onglets d'événement. */

.page-head { display: flex; flex-direction: column; gap: 6px; margin-bottom: 24px; }
.page-head h1 { font-size: 26px; letter-spacing: -.02em; }
.page-head p { color: var(--muted); font-size: 14px; max-width: 60ch; }
.eyebrow {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 11px; letter-spacing: .14em; text-transform: uppercase;
  color: var(--muted);
}

.feed { display: flex; flex-direction: column; gap: 14px; }

.docket {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px 20px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 16px 22px;
  align-items: start;
}
.docket-main { min-width: 0; display: flex; flex-direction: column; gap: 12px; }
.docket-top { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
.docket-kind {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10.5px; letter-spacing: .13em; text-transform: uppercase;
  color: var(--muted);
  border: 1px solid var(--border); border-radius: 3px; padding: 2px 6px;
}
.docket-title { font-size: 17px; font-weight: 600; letter-spacing: -.02em; }
.docket-meta {
  display: flex; flex-wrap: wrap; gap: 4px 14px;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 11.5px; color: var(--muted);
}
.docket-hint { font-size: 13px; color: var(--muted); }
.docket-side { display: flex; flex-direction: column; gap: 10px; min-width: 180px; }
.docket-side .btn { justify-content: center; }

/* ── La jauge ───────────────────────────────────────────────────────────── */
/* Un segment par pose : le nombre de segments EST le format acheté. Au-delà de
   60 poses (les événements) les segments deviendraient des traits d'un pixel,
   et dashboard.js bascule sur la barre continue ci-dessous. */

.gauge-block { display: flex; flex-direction: column; gap: 7px; }
.gauge { display: flex; gap: 2px; height: 22px; align-items: stretch; }
.gauge-seg { flex: 1 1 0; min-width: 2px; border-radius: 1.5px; background: var(--surface2); }
.gauge-seg[data-on="1"] { background: var(--accent); }
.gauge[data-tone="done"] .gauge-seg[data-on="1"] { background: var(--success); }
.gauge[data-tone="idle"] .gauge-seg[data-on="1"] { background: var(--inert); }

.gauge-solid { height: 22px; border-radius: 3px; background: var(--surface2); overflow: hidden; }
.gauge-solid-fill { height: 100%; background: var(--accent); border-radius: 3px; }
.gauge-solid[data-tone="done"] .gauge-solid-fill { background: var(--success); }
.gauge-solid[data-tone="idle"] .gauge-solid-fill { background: var(--inert); }

.frames {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 12px; color: var(--text);
  display: flex; align-items: baseline; gap: 5px;
}
.frames span { color: var(--muted); }

/* ── Pastille d'étape ───────────────────────────────────────────────────── */
/* Distincte de `.badge`, qui reste utilisée ailleurs. Quatre états seulement :
   le client a besoin de savoir si c'est en cours, en route, arrivé ou arrêté —
   pas de connaître les sept valeurs de la colonne. */

.chip {
  display: inline-flex; align-items: center; gap: 6px;
  font-size: 11.5px; font-weight: 600; padding: 3px 10px;
  border-radius: 999px; border: 1px solid transparent;
  background: var(--surface2); color: var(--muted); white-space: nowrap;
}
/* Maquette B : une pastille pleine se lit sans le point de couleur d'avant. */
.chip[data-state="shooting"] { color: var(--accent); background: var(--accent-bg); }
.chip[data-state="lab"] { color: var(--blue); background: #16233d; }
.chip[data-state="done"] { color: var(--success); background: var(--success-bg); }
.chip[data-state="wait"], .chip[data-state="stopped"] { color: var(--muted); background: var(--surface2); }

/* ── Fiches pellicule et événement : page qui défile ───────────────────────
   Refonte du 2026-09-27 (spec § 3 et § 4, maquette C « page qui défile ») :
   en-tête nu (nom, identifiant, pastille), barre d'actions juste dessous, puis
   des sections empilées, chacune dans sa carte. Plus d'onglets : tout se lit
   en faisant défiler, et les formulaires d'achat s'ouvrent dans le panneau. */

.sheet-head {
  display: flex; flex-direction: column; gap: 18px;
  margin-bottom: 8px;
}
.sheet-head-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 18px; flex-wrap: wrap; }
.sheet-head h1 { font-size: 26px; letter-spacing: -.02em; }

/* Seulement les actions possibles ; le remboursement en bouton discret, à la
   fin — c'est un droit, pas une invitation. */
.sheet-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; }
.btn-quiet { background: transparent; border-color: transparent; color: var(--muted); font-weight: 500; }
.btn.btn-quiet:hover { color: var(--text); border-color: var(--border); }

.sheet-section { margin-top: 32px; }
.sheet-section-title {
  font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 12px;
}
.sheet-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  display: flex; flex-direction: column; gap: 18px;
}
/* Dans sa carte, le bloc de faits n'a plus besoin du filet qui le séparait de
   l'en-tête ; celui du remboursement reste (action à conséquence). */
.sheet-card > .facts:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.sheet-card > .refund-block:first-child { margin-top: 0; padding-top: 0; border-top: 0; }
.sheet-card > .refund-block { margin-top: 0; }
.sheet-card .table-scroll { margin: -4px 0; }
/* Fiche événement : « Télécharger les photos » est dans la barre d'actions, et
   seulement quand l'archive est prête. Le bouton de la galerie ferait doublon —
   ou, désactivé, annoncerait une action que la barre ne propose pas. */
#event-gallery .gallery-toolbar { display: none; }
/* Historique des commandes de tirages : sous ~480 px, les cinq en-têtes se
   touchaient (« QTÉMONTANT »). Largeur minimale, et la carte défile. */
#event-print-orders .sheet-card { overflow-x: auto; }
#event-print-orders .reprints-orders-table { min-width: 480px; }
#event-print-orders .reprints-orders-table th { padding-right: 12px; }
/* Le bouton « Actualiser » de la Progression, aligné sur le titre de section. */
#event-progress [data-section-body="progress"] > div:first-child { margin-top: -6px; }

@media (max-width: 560px) {
  .sheet-head h1 { font-size: 22px; }
  .sheet-actions .btn { flex: 1 1 auto; }
  .sheet-actions .btn-quiet { flex-basis: 100%; }
  .sheet-card { padding: 16px; }
  .sheet-section { margin-top: 26px; }
}
.sheet-id {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 12px; color: var(--muted); margin-top: 4px;
}

/* Les étapes racontent le colis ; la jauge compte les poses. Deux dispositifs,
   deux informations — c'est le point de la refonte. */
.stages { display: flex; gap: 0; }
.stage { flex: 1 1 0; min-width: 0; display: flex; flex-direction: column; gap: 7px; }
.stage-bar { height: 3px; border-radius: 2px; background: var(--border); margin-right: 3px; }
.stage[data-on="1"] .stage-bar { background: var(--success); }
.stage[data-on="now"] .stage-bar { background: var(--accent); }
.stage-label { font-size: 11.5px; color: var(--muted); padding-right: 8px; }
.stage[data-on="1"] .stage-label { color: var(--text); }
.stage[data-on="now"] .stage-label { color: var(--accent); }
.stage-when {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10.5px; color: var(--muted);
}

/* ── Planche contact ────────────────────────────────────────────────────── */

.contact { display: grid; grid-template-columns: repeat(auto-fill, minmax(96px, 1fr)); gap: 8px; }
.frame {
  position: relative; aspect-ratio: 3/4; border-radius: 3px; overflow: hidden;
  border: 1px solid var(--border); background: var(--surface2);
  cursor: zoom-in; padding: 0;
}
.frame:hover { border-color: var(--accent); }
.frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.frame-no {
  position: absolute; left: 5px; bottom: 4px;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 9.5px; color: rgba(255,255,255,.75);
  text-shadow: 0 1px 2px rgba(0,0,0,.8);
}

/* ── Tableau de commandes ───────────────────────────────────────────────── */

.table-scroll { overflow-x: auto; }
.table-scroll table { width: 100%; border-collapse: collapse; font-size: 13.5px; min-width: 520px; }
.table-scroll th {
  text-align: left;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase;
  color: var(--muted); font-weight: 400;
  padding: 0 12px 9px 0; border-bottom: 1px solid var(--border);
}
.table-scroll td { padding: 13px 12px 13px 0; border-bottom: 1px solid var(--border); vertical-align: middle; }
.table-scroll tr:last-child td { border-bottom: none; }
.num { font-family: ui-monospace, 'SF Mono', Menlo, monospace; font-variant-numeric: tabular-nums; }
.muted-cell { color: var(--muted); }
.link-cell { color: var(--blue); text-decoration: none; }
.link-cell:hover { text-decoration: underline; }

/* ── État vide ──────────────────────────────────────────────────────────── */

.empty {
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  padding: 36px 24px;
  text-align: center;
  display: flex; flex-direction: column; align-items: center; gap: 10px;
}
.empty h3 { font-size: 16px; }
.empty p { color: var(--muted); font-size: 14px; max-width: 44ch; }

@media (max-width: 640px) {
  .docket { grid-template-columns: 1fr; }
  .docket-side { min-width: 0; }
  .stages { flex-wrap: wrap; gap: 10px 0; }
  .stage { flex: 1 1 45%; }
  .contact { grid-template-columns: repeat(auto-fill, minmax(74px, 1fr)); }
}

/* ── Tunnel de réimpression ─────────────────────────────────────────────── */

.reorder { display: grid; grid-template-columns: 1fr 300px; gap: 20px; align-items: start; }

.panel {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
}
.panel h3 { font-size: 15px; margin-bottom: 4px; }
.panel-sub { font-size: 13px; color: var(--muted); margin-bottom: 14px; line-height: 1.45; }

.recipient {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 14px;
  background: var(--surface2);
  display: flex; flex-direction: column; gap: 10px;
}
.recipient + .recipient { margin-top: 10px; }
.recipient-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.recipient-rank {
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 10.5px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted);
}
.recipient-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.recipient-grid-zip { grid-template-columns: 110px 1fr; }
.recipient .form-input { margin: 0; }

.stepper { display: flex; align-items: center; gap: 10px; }
.stepper-btn {
  width: 32px; height: 32px; border-radius: 8px;
  border: 1px solid var(--border); background: var(--surface);
  color: var(--text); cursor: pointer; font-size: 17px; line-height: 1;
  display: grid; place-items: center;
}
.stepper-btn:hover:not([disabled]) { border-color: var(--accent); color: var(--accent); }
.stepper-btn[disabled] { opacity: .4; cursor: not-allowed; }
.stepper-val { font-size: 14px; min-width: 22px; text-align: center; }
.stepper-label { font-size: 12.5px; color: var(--muted); }

.summary { position: sticky; top: 20px; }
.sum-line { display: flex; justify-content: space-between; gap: 14px; font-size: 13.5px; padding: 7px 0; }
.sum-line span:first-child { color: var(--text); }
.sum-total {
  display: flex; justify-content: space-between; align-items: baseline;
  border-top: 1px solid var(--border); margin-top: 10px; padding-top: 14px;
}
.sum-total span { font-size: 13px; color: var(--muted); }
.sum-total b { font-size: 24px; font-weight: 500; color: var(--accent); }
.sum-note { font-size: 12px; color: var(--muted); margin-top: 12px; line-height: 1.5; }

@media (max-width: 760px) {
  .reorder { grid-template-columns: 1fr; }
  .summary { position: static; }
}

.page-note { font-size: 12.5px; color: var(--muted); margin-top: 14px; line-height: 1.5; max-width: 70ch; }
.right { text-align: right; }
.table-scroll td .muted-cell { font-size: 12px; margin-top: 2px; }


/* ── Vignettes du fil ───────────────────────────────────────────────────── */
/* Vides tant que rien n'est chargé : le conteneur ne réserve pas de place, une
   carte sans photo ne doit pas afficher un trou. */
.thumbs { display: flex; gap: 4px; }
.thumbs:empty { display: none; }
.thumb {
  width: 44px; height: 44px; border-radius: 3px; flex: none;
  border: 1px solid var(--border);
  background-size: cover; background-position: center;
}
.thumb-more {
  width: 44px; height: 44px; border-radius: 3px; flex: none;
  border: 1px dashed var(--border);
  display: grid; place-items: center;
  font-family: ui-monospace, 'SF Mono', Menlo, monospace;
  font-size: 11px; color: var(--muted);
}

/* Une commande partie sur une pellicule déjà livrée : la carte ne changeait
   pas d'un iota après l'achat. */
.docket-flight {
  font-size: 13px;
  color: var(--accent);
  display: flex; align-items: center; gap: 7px;
}
.docket-flight::before {
  content: ''; width: 6px; height: 6px; border-radius: 50%;
  background: var(--accent); flex: none;
}

/* ── Bloc de faits des fiches (pellicule et événement) ──────────────────────
   Une grille à deux colonnes qui retombe en une seule sous 560 px : sur mobile,
   un libellé et sa valeur côte à côte laissent trop peu de place à l'adresse,
   qui est la valeur la plus longue et la plus utile du bloc. */
.facts {
  margin-top: 18px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
  display: grid;
  gap: 10px 24px;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
}
.fact { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.fact dt {
  font-size: 11px; letter-spacing: .06em; text-transform: uppercase;
  color: var(--muted); font-weight: 600;
}
.fact dd { font-size: 14px; color: var(--text); margin: 0; min-width: 0; }
/* `break-word` et non `nowrap` : un numéro de suivi long doit se couper plutôt
   que d'élargir la page — le débordement horizontal est le défaut le plus
   pénible à rattraper sur mobile. */
.fact dd .mono, .tracking-number {
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-size: 13px; overflow-wrap: anywhere;
}
.tracking-line { display: flex; flex-wrap: wrap; align-items: baseline; gap: 8px; }
.tracking-line + .tracking-line { margin-top: 4px; }
.tracking-label { font-size: 11px; color: var(--muted); }
.tracking-line a { color: var(--accent); text-decoration: underline; }
.sheet-recipient { display: flex; flex-direction: column; }
.sheet-recipient-name { font-weight: 600; }
.sheet-recipient-line { color: var(--muted); font-size: 13px; }

@media (max-width: 560px) {
  .facts { grid-template-columns: 1fr; }
}

/* Bloc de retractation, en pied de fiche. Separe du reste par un filet : c'est
   une action a consequence, elle ne doit pas se confondre avec les faits qui la
   precedent. Quand elle n'est pas possible, seule la phrase d'explication
   subsiste — une absence de bouton sans explication passe pour un bug. */
.refund-block { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--border); display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.refund-block p { margin: 0; flex: 1 1 220px; font-size: 13px; }

/* ── Accueil : En cours / Terminées ou annulées (refonte du 2026-09-27) ──────
   Maquette B « sombre aéré » : une grille de cartes (vignette, titre, méta,
   pastille), la section « Terminées ou annulées » repliée en dessous. Les
   classes `.order-row`, `.row-*` et `.chip` sont celles de l'ancien fil : le
   harnais et `dashboard.js` les visent, seule leur mise en page change. */

.home-head { margin-bottom: 28px; }
.home-head h1 { font-size: 28px; }

.feed-section { margin-bottom: 32px; }
.feed-section-title {
  font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase;
  color: var(--muted); margin: 0 0 12px;
}
.feed-none { color: var(--muted); font-size: 14px; padding: 18px 0; }

.feed-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(300px, 100%), 1fr)); gap: 12px; }

.order-row {
  display: flex; align-items: flex-start; gap: 14px;
  padding: 14px; min-width: 0;
  border: 1px solid var(--border); border-radius: var(--radius);
  background: var(--surface);
  text-decoration: none; color: inherit;
  transition: border-color .15s, background .15s, transform .15s, opacity .15s;
}
.order-row:hover { border-color: #3a3a40; background: #202024; }
.order-row:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
/* Le déplacement est minuscule et c'est voulu : sur une grille de dix cartes,
   un survol qui saute donne le tournis. */
.order-row:active { transform: translateY(1px); }

/* Vignette : première photo révélée, sinon pictogramme du type. */
.feed-thumb {
  width: 56px; height: 56px; flex: none; border-radius: 10px;
  background: var(--surface2) center / cover no-repeat;
  display: grid; place-items: center; color: var(--muted);
}
.feed-thumb.has-photo { background-color: transparent; }

.row-body { flex: 1 1 auto; min-width: 0; display: flex; flex-direction: column; gap: 3px; }
/* `min-width: 0` + `ellipsis` : un nom long se coupe lui-même au lieu
   d'élargir la carte. */
.row-title {
  font-weight: 600; font-size: 15px; color: var(--text);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0;
}
.row-meta { font-size: 12.5px; color: var(--muted); }
.row-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 6px; }

/* La jauge, réduite à un trait, seulement pendant la prise de vue. */
.row-progress { display: block; height: 3px; border-radius: 2px; background: var(--border); margin-top: 8px; overflow: hidden; }
.row-progress > span { display: block; height: 100%; background: var(--accent); }
.row-progress[data-tone="done"] > span { background: var(--success); }
.row-progress[data-tone="idle"] > span { background: var(--muted); }

.row-flight { font-size: 12px; color: var(--accent); margin-top: 4px; }
.row-flight[hidden] { display: none; }

.row-cta {
  font-size: 12px; font-weight: 600; color: #111;
  background: var(--accent); border-radius: 999px; padding: 4px 11px;
  white-space: nowrap;
}
/* Variante discrète : la réimpression est une offre, pas une urgence. */
.row-cta.is-quiet { background: transparent; color: var(--accent); border: 1px solid rgba(245,171,0,.5); cursor: pointer; }
.row-cta.is-quiet:hover, .row-cta.is-quiet:focus-visible { background: var(--accent); color: #111; outline: none; }

/* Repli de « Terminées ou annulées » : un `<details>` natif. */
.feed-fold > summary {
  list-style: none; cursor: pointer;
  display: flex; justify-content: space-between; align-items: center; gap: 12px;
  background: var(--surface); border: 1px solid var(--border); border-radius: 10px;
  padding: 12px 14px; font-size: 13.5px; color: var(--muted);
}
.feed-fold > summary::-webkit-details-marker { display: none; }
.feed-fold > summary:hover { color: var(--text); }
.feed-fold > summary:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.feed-fold-show::after { content: ' ›'; }
.feed-fold-hide { display: none; }
.feed-fold[open] .feed-fold-show { display: none; }
.feed-fold[open] .feed-fold-hide { display: inline; }
.feed-fold[open] > summary { margin-bottom: 12px; }

/* Plus discrètes : on les retrouve, mais le regard tombe d'abord sur ce qui bouge. */
/* Relecture du 2026-09-27 : plus d'`opacity` sur la carte entière — elle
   ramenait le texte secondaire sous 4,5:1. Seuls la vignette et le cadre
   s'effacent ; le texte garde ses couleurs (contraste AA). */
.order-row.is-done { background: transparent; }
.order-row.is-done .feed-thumb { opacity: .5; }
.order-row.is-done:hover .feed-thumb, .order-row.is-done:focus-visible .feed-thumb { opacity: 1; }

@media (max-width: 560px) {
  .home-head h1 { font-size: 24px; }
  .feed-grid { grid-template-columns: 1fr; }
  .order-row { padding: 12px; gap: 12px; }
  .feed-thumb { width: 48px; height: 48px; }
}

/* ── Panneau latéral (js/drawer.js, refonte du 2026-09-27) ──────────────────
   Conteneur des formulaires d'achat ouverts depuis une fiche. À droite à
   partir de 900 px, plein écran en dessous. z-index 900 : SOUS la fenêtre de
   paiement et la visionneuse (1000) et l'alerte de session (1100), qui
   s'ouvrent par-dessus lui. */
body.drawer-open { overflow: hidden; }
.drawer-root { position: fixed; inset: 0; z-index: 900; }
.drawer-veil { position: absolute; inset: 0; background: rgba(0,0,0,.6); }
.drawer {
  position: absolute; top: 0; right: 0; bottom: 0;
  width: min(640px, 100%);
  background: var(--bg); border-left: 1px solid var(--border);
  display: flex; flex-direction: column;
  box-shadow: -24px 0 48px rgba(0,0,0,.45);
  outline: none;
}
.drawer-head {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 18px 24px; border-bottom: 1px solid var(--border);
}
.drawer-title { font-size: 17px; font-weight: 700; }
.drawer-close {
  width: 36px; height: 36px; flex: none; border-radius: 10px;
  border: 1px solid var(--border); background: var(--surface); color: var(--text);
  font-size: 15px; cursor: pointer;
}
.drawer-close:hover { border-color: #3a3a40; }
.drawer-close:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.drawer-body { flex: 1 1 auto; overflow-y: auto; padding: 20px 24px 32px; -webkit-overflow-scrolling: touch; }
/* Dans le panneau, le tunnel de réimpression tient sur une colonne : sa grille
   « formulaire + récapitulatif » se règle sur la largeur de la FENÊTRE, pas du
   panneau, et y serait écrasée. */
.drawer .reorder { grid-template-columns: 1fr; }
.drawer .summary { position: static; }
/* Sélection de photos : sous ~340 px, les deux boutons débordaient du panneau. */
.drawer .reprints-select-bar { flex-wrap: wrap; gap: 8px; }
@media (max-width: 899px) {
  .drawer { width: 100%; border-left: 0; box-shadow: none; }
  .drawer-head { padding: 14px 16px; }
  .drawer-body { padding: 16px 16px 28px; }
}

/* ── Bandeau « achetez dans l'application » + pages d'explication (2026-10-14) ─
   Le portail ne vend rien : le bandeau le dit en haut de l'accueil, et la page
   « Comment ça marche » reprend le même bloc en pied. */

.buy-banner {
  display: flex; align-items: center; justify-content: space-between; gap: 16px;
  padding: 14px 16px; margin-bottom: 24px;
  border: 1px solid var(--accent); border-radius: var(--radius);
  background: var(--accent-bg);
}
.buy-banner > div { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.buy-banner strong { font-size: 14px; }
.buy-banner span { font-size: 13px; color: var(--muted); }
.buy-banner .btn { flex: none; text-decoration: none; }
@media (max-width: 680px) {
  .buy-banner { flex-direction: column; align-items: stretch; text-align: left; }
  .buy-banner .btn { text-align: center; }
}

/* Pellicule : cinq vues numérotées entre deux rangées de perforations. */
.how-strip {
  list-style: none; margin: 0 0 28px; padding: 22px 12px;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); gap: 12px;
  background: #0a0a0b; border-radius: var(--radius);
  background-image:
    repeating-linear-gradient(90deg, var(--surface2) 0 10px, transparent 10px 22px),
    repeating-linear-gradient(90deg, var(--surface2) 0 10px, transparent 10px 22px);
  background-size: 100% 6px, 100% 6px;
  background-position: 0 6px, 0 calc(100% - 6px);
  background-repeat: no-repeat;
}
.how-frame {
  position: relative; display: flex; flex-direction: column; gap: 8px;
  padding: 16px 14px; border-radius: 10px;
  background: var(--surface); border: 1px solid var(--border);
  animation: how-in .5s ease both; animation-delay: calc(var(--i) * 90ms);
  transition: transform .2s, border-color .2s;
}
.how-frame:hover { transform: translateY(-4px) rotate(-.6deg); border-color: var(--accent); }
.how-frame h3 { font-size: 15px; margin: 0; }
.how-frame p { font-size: 13px; color: var(--muted); margin: 0; line-height: 1.5; }
.how-num {
  position: absolute; top: 10px; right: 12px;
  font-size: 11px; font-weight: 700; color: var(--inert); letter-spacing: .08em;
}
.how-icon {
  width: 48px; height: 48px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  color: var(--accent); background: var(--accent-bg);
}
@keyframes how-in { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }

/* « Photo cachée » qui se révèle en boucle : floue, puis nette. */
.how-reveal {
  display: flex; align-items: center; gap: 16px; margin-bottom: 32px;
  padding: 14px; border: 1px dashed var(--border); border-radius: var(--radius);
}
.how-reveal-photo {
  flex: none; width: 88px; height: 64px; border-radius: 8px;
  background: linear-gradient(135deg, #f5ab00 0%, #ff7a59 45%, #6ea0ff 100%);
  filter: blur(14px) grayscale(.6);
  animation: how-reveal 5s ease-in-out infinite;
}
.how-reveal-text { font-size: 13px; color: var(--muted); }
@keyframes how-reveal {
  0%, 35% { filter: blur(14px) grayscale(.6); }
  60%, 85% { filter: blur(0) grayscale(0); }
  100% { filter: blur(14px) grayscale(.6); }
}

.how-h2 { font-size: 11px; font-weight: 600; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); margin: 0 0 12px; }
.how-modes { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 12px; margin-bottom: 28px; }
.how-mode { padding: 16px; border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.how-mode h3 { font-size: 16px; margin: 0 0 6px; }
.how-mode p { font-size: 13px; color: var(--muted); margin: 0; line-height: 1.55; }
.how-sizes { display: flex; gap: 8px; margin-top: 12px; }
.how-sizes span {
  min-width: 40px; padding: 6px 10px; text-align: center; border-radius: 8px;
  font-weight: 700; font-size: 13px; color: var(--accent); background: var(--accent-bg);
}
.how-cta { margin-top: 8px; }

@media (prefers-reduced-motion: reduce) {
  .how-frame, .how-reveal-photo { animation: none; }
  .how-reveal-photo { filter: none; }
  .how-frame:hover { transform: none; }
}

/* FAQ : `<details>` natifs, ouvrables au clavier. */
.faq-list { display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.faq-item { border: 1px solid var(--border); border-radius: var(--radius); background: var(--surface); }
.faq-item summary {
  cursor: pointer; list-style: none; padding: 14px 16px; font-size: 14px; font-weight: 600;
  display: flex; justify-content: space-between; gap: 12px;
}
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: '+'; color: var(--accent); font-size: 18px; line-height: 1; }
.faq-item[open] summary::after { content: '−'; }
.faq-answer { padding: 0 16px 14px; }
.faq-answer p { font-size: 13px; color: var(--muted); line-height: 1.6; margin: 0 0 8px; }
.faq-more { margin-top: 20px; font-size: 13px; color: var(--muted); }
.faq-more a { color: var(--accent); }
