:root {
  --bg: #f5f6fb;
  --bg-soft: #ffffff;
  --card: #ffffff;
  --border: #e6e8f2;
  --text: #171b34;
  --text-muted: #6b7086;
  --primary: #f2711c;
  --primary-hover: #ff8a3d;
  --success: #1c9a6c;
  --danger: #e0483c;
  --warning: #c98a06;
  --radius: 10px;
  --shadow-sm: 0 1px 2px rgba(23, 27, 52, 0.05), 0 1px 4px rgba(23, 27, 52, 0.04);
  --shadow-md: 0 10px 24px rgba(23, 27, 52, 0.09);
  --shadow-primary: 0 8px 20px rgba(242, 113, 28, 0.28);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

* { box-sizing: border-box; }
[x-cloak] { display: none !important; }

html { height: 100%; }
body {
  margin: 0;
  min-height: 100%;
  display: flex;
  flex-direction: column;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
  animation: pageFadeIn 0.45s var(--ease) both;
}
.main { flex: 1 0 auto; }
.site-footer { flex-shrink: 0; }

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to { opacity: 1; transform: none; }
}

a { color: var(--primary); text-decoration: none; transition: color 0.15s ease; }
a:hover { color: var(--primary-hover); }

.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
}

.topbar {
  height: 4px;
  background: linear-gradient(90deg, var(--primary), #ffb347, #ff5a1f, var(--primary));
  background-size: 300% 100%;
  animation: shimmer 8s linear infinite;
}
@keyframes shimmer {
  0% { background-position: 0% 0; }
  100% { background-position: 300% 0; }
}

.navbar {
  background: var(--bg-soft);
  border-bottom: 1px solid var(--border);
  padding: 8px 0;
  position: sticky;
  top: 0;
  z-index: 20;
  box-shadow: var(--shadow-sm);
}

.navbar .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.brand {
  display: inline-flex;
  align-items: center;
}
.brand-logo {
  height: 52px;
  width: auto;
  display: block;
  transition: transform 0.3s var(--ease);
}
.brand:hover .brand-logo { transform: scale(1.05) rotate(-2deg); }

.nav-links {
  display: flex;
  gap: 18px;
  align-items: center;
  flex-wrap: wrap;
}

.nav-links a, .nav-links button.linklike {
  color: var(--text-muted);
  font-size: 0.92rem;
  background: none;
  border: none;
  cursor: pointer;
  padding: 2px 0;
  font-family: inherit;
  position: relative;
  transition: color 0.15s ease;
}
.nav-links a:not(.btn)::after, .nav-links button.linklike::after {
  content: "";
  position: absolute;
  left: 0; right: 100%;
  bottom: -2px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  transition: right 0.25s var(--ease);
}
.nav-links a:not(.btn):hover, .nav-links button.linklike:hover { color: var(--text); }
.nav-links a:not(.btn):hover::after, .nav-links button.linklike:hover::after { right: 0; }
.nav-links .nav-cta { background: var(--primary); color: #fff; padding: 8px 16px; }
.nav-links .nav-cta:hover { background: var(--primary-hover); color: #fff; }
.nav-links .nav-user {
  background: var(--bg);
  border-radius: 999px;
  padding: 5px 12px;
  font-weight: 600;
  color: var(--text) !important;
  font-size: 0.85rem;
}

.main { padding: 32px 0 64px; }

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

a.card:hover, .event-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.grid {
  display: grid;
  gap: 20px;
}
.grid-3 { grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.grid-2 { grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); }

.grid > * {
  animation: cardIn 0.45s var(--ease) both;
}
.grid > *:nth-child(1) { animation-delay: 0.02s; }
.grid > *:nth-child(2) { animation-delay: 0.07s; }
.grid > *:nth-child(3) { animation-delay: 0.12s; }
.grid > *:nth-child(4) { animation-delay: 0.17s; }
.grid > *:nth-child(5) { animation-delay: 0.22s; }
.grid > *:nth-child(6) { animation-delay: 0.27s; }

@keyframes cardIn {
  from { opacity: 0; transform: translateY(14px); }
  to { opacity: 1; transform: none; }
}

.btn {
  display: inline-block;
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 18px;
  font-size: 0.95rem;
  cursor: pointer;
  font-weight: 600;
  transition: transform 0.15s var(--ease), box-shadow 0.15s var(--ease), background-color 0.15s ease;
  box-shadow: var(--shadow-primary);
}
.btn:hover { background: var(--primary-hover); color: #fff; transform: translateY(-2px); box-shadow: 0 12px 24px rgba(242, 113, 28, 0.35); }
.btn:active { transform: translateY(0) scale(0.97); box-shadow: var(--shadow-primary); }
.btn.secondary { background: transparent; border: 1px solid var(--border); color: var(--text); box-shadow: none; }
.btn.secondary:hover { background: var(--bg); border-color: var(--text-muted); transform: translateY(-2px); box-shadow: var(--shadow-sm); }
.btn.danger { background: var(--danger); box-shadow: 0 8px 20px rgba(224, 72, 60, 0.28); }
.btn.danger:hover { background: #c8392e; }
.btn.small { padding: 6px 12px; font-size: 0.85rem; }
.btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none !important; }

.form-group { margin-bottom: 16px; }
.form-group label { display: block; margin-bottom: 6px; font-size: 0.88rem; color: var(--text-muted); }
.form-group input, .form-group select, .form-group textarea {
  width: 100%;
  padding: 10px 12px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--text);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.form-group input:focus, .form-group select:focus, .form-group textarea:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(242, 113, 28, 0.15);
}
.form-row { display: flex; gap: 16px; flex-wrap: wrap; }
/* min() plutôt qu'une valeur fixe : sur un écran plus étroit que 180px+marges,
   un min-width fixe forcerait le champ (et donc toute la page) à déborder
   horizontalement au lieu de passer sur sa propre ligne. */
.form-row > .form-group { flex: 1; min-width: min(180px, 100%); }

.alert {
  padding: 12px 16px;
  border-radius: 8px;
  margin-bottom: 16px;
  font-size: 0.92rem;
  animation: alertIn 0.3s var(--ease) both;
}
@keyframes alertIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: none; }
}
.alert.error { background: rgba(224,72,60,0.08); color: #b5342a; border: 1px solid rgba(224,72,60,0.25); }
.alert.success { background: rgba(28,154,108,0.08); color: #157e58; border: 1px solid rgba(28,154,108,0.25); }

.badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  transition: transform 0.15s ease;
}
.badge.valid { background: rgba(28,154,108,0.1); color: #157e58; }
.badge.used { background: rgba(107,112,134,0.12); color: var(--text-muted); }
.badge.refunded, .badge.cancelled { background: rgba(224,72,60,0.1); color: #b5342a; }
.badge.published { background: rgba(28,154,108,0.1); color: #157e58; }
.badge.draft { background: rgba(201,138,6,0.12); color: #9a6c04; }
.badge.open { background: rgba(201,138,6,0.12); color: #9a6c04; animation: badgePulse 1.8s ease-in-out infinite; }
.badge.resolved { background: rgba(28,154,108,0.1); color: #157e58; }
.badge.rejected { background: rgba(107,112,134,0.12); color: var(--text-muted); }

@keyframes badgePulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.55; }
}

h1 { font-size: 1.8rem; margin: 0 0 8px; }
h2 { font-size: 1.3rem; margin: 0 0 16px; }
.muted { color: var(--text-muted); }
.price { font-weight: 700; color: var(--text); }

/* display:block + overflow-x:auto directement sur <table> (plutôt qu'un div
   wrapper à ajouter dans chaque vue) : sur un écran étroit, un tableau à
   plusieurs colonnes scrolle horizontalement dans sa propre boîte au lieu de
   forcer toute la page à déborder. thead/tbody/tr/td gardent leur affichage
   "table-*" par défaut, donc les colonnes restent alignées normalement. */
table { display: block; overflow-x: auto; -webkit-overflow-scrolling: touch; width: 100%; border-collapse: collapse; }
th, td { text-align: left; padding: 10px 12px; border-bottom: 1px solid var(--border); font-size: 0.9rem; }
th { color: var(--text-muted); font-weight: 600; }
tbody tr { transition: background-color 0.15s ease; }
tbody tr:hover { background: var(--bg); }

.event-card { display: flex; flex-direction: column; gap: 8px; }
.event-card .cover {
  height: 140px;
  border-radius: 8px;
  background: linear-gradient(135deg, var(--primary), #1b2340);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 2rem;
  overflow: hidden;
  transition: transform 0.4s var(--ease);
}
.event-card:hover .cover { transform: scale(1.04); }

.pagination { display: flex; gap: 8px; margin-top: 24px; justify-content: center; }
.pagination a, .pagination span {
  padding: 8px 14px; border-radius: 6px; border: 1px solid var(--border);
  transition: transform 0.15s ease, background-color 0.15s ease;
}
.pagination a:hover { background: var(--bg); transform: translateY(-2px); }
.pagination .current { background: var(--primary); border-color: var(--primary); color: #fff; }

.qr-box {
  background: #fff;
  padding: 16px;
  border-radius: 8px;
  display: inline-block;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}
.qr-box canvas, .qr-box img { animation: popIn 0.4s var(--ease) both; }
@keyframes popIn {
  from { opacity: 0; transform: scale(0.85); }
  to { opacity: 1; transform: none; }
}

/* --- Billet électronique (design "ticket-stub", type billet physique) ---
   Le talon QR reste à droite (comme un vrai billet déchirable). La colonne
   photo, elle, ne recadre jamais l'image : elle est centrée en "contain"
   sur un fond dégradé, donc toujours visible en entier quel que soit son
   format (bannière large, affiche verticale...) — c'est la hauteur du talon
   QR qui fixe la hauteur du billet, la photo s'y ajuste sans être coupée. */
.eticket-stub {
  display: flex;
  flex-direction: row;
  box-shadow: var(--shadow-md);
  animation: cardIn 0.45s var(--ease) both;
  background: #fff;
  border-radius: 16px;
  overflow: hidden;
}
@media (max-width: 640px) { .eticket-stub { flex-direction: column; } }

.eticket-stub-main {
  flex: 2.6;
  min-width: 0;
  display: flex;
  flex-direction: column;
}

/* position:absolute + inset (plutôt que max-width/max-height sur un img en
   flux normal) car c'est la seule technique fiable pour qu'un enfant occupe
   toute la hauteur "stretchée" d'un item flex — les pourcentages de hauteur
   sur un enfant en flux normal ne s'y résolvent pas de façon fiable.
   object-fit:cover (plutôt que contain) pour que la photo remplisse tout le
   panneau sans aucune bande vide, y compris à l'impression — quitte à rogner
   légèrement les bords, ce qui reste minime vu le ratio large du panneau. */
.eticket-stub-main.photo-only {
  position: relative;
  min-height: 150px;
  background: linear-gradient(160deg, var(--eticket-accent, #1b2340), #12162c);
}
.eticket-stub-main.photo-only img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}
/* Quand le panneau respecte déjà le ratio exact de la photo (voir aspect-ratio
   inline, calculé côté serveur), plus besoin de recadrer : la photo remplit
   pile le panneau. */
.eticket-stub-main.photo-only img.exact-fit {
  object-fit: contain;
}

/* Sans photo : on affiche le texte (titre, lieu, date, catégorie...) sur un
   fond en dégradé de la couleur d'accent, faute d'autre visuel disponible. */
.eticket-stub-content {
  flex: 1;
  padding: 16px 22px 18px;
  color: #fff;
  background: linear-gradient(160deg, var(--eticket-accent, #1b2340), #12162c);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 14px;
}

.eticket-brand-mini {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255,255,255,0.95);
  color: #171b34;
  padding: 6px 12px 6px 6px;
  border-radius: 999px;
  width: fit-content;
  font-weight: 700;
  font-size: 0.85rem;
}
.eticket-brand-mini img { height: 22px; width: 22px; object-fit: contain; }

.eticket-stub-title { font-size: 1.4rem; font-weight: 800; line-height: 1.15; margin: 0; }
.eticket-stub-sub { font-size: 0.85rem; opacity: 0.92; display: flex; align-items: center; gap: 6px; flex-wrap: wrap; }

.eticket-badge-row { display: flex; gap: 8px; flex-wrap: wrap; }
.eticket-pill {
  display: inline-block;
  padding: 5px 12px;
  border-radius: 999px;
  font-size: 0.78rem;
  font-weight: 700;
  background: rgba(255,255,255,0.16);
  backdrop-filter: blur(2px);
}
.eticket-pill.accent { background: var(--primary); }

.eticket-stub-side {
  flex: 1;
  min-width: 160px;
  background: #fff;
  color: #171b34;
  padding: 10px 10px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  gap: 4px;
  position: relative;
  border-radius: 0 16px 16px 0;
  border-left: 2px dashed #b9bdcc;
}
.eticket-stub-side .qr-box { padding: 10px; }
@media (max-width: 640px) {
  .eticket-stub-side { border-radius: 0 0 16px 16px; border-left: none; border-top: 2px dashed #b9bdcc; }
}
.eticket-stub-side::before,
.eticket-stub-side::after {
  content: "";
  position: absolute;
  width: 22px;
  height: 22px;
  background: var(--bg);
  border-radius: 50%;
  z-index: 2;
}
.eticket-stub-side::before { left: -11px; top: -11px; }
.eticket-stub-side::after { left: -11px; bottom: -11px; }
@media (max-width: 640px) {
  .eticket-stub-side::before { left: -11px; top: -11px; }
  .eticket-stub-side::after { left: auto; right: -11px; top: -11px; bottom: auto; }
}

.eticket-stub-brand { display: flex; align-items: center; gap: 5px; font-weight: 800; font-size: 0.9rem; color: #171b34; }
.eticket-stub-brand img { height: 20px; width: 20px; object-fit: contain; }
.eticket-scan-label { margin: 0; font-size: 0.66rem; line-height: 1.25; font-weight: 700; letter-spacing: 0.03em; color: var(--text-muted); text-transform: uppercase; }

.eticket-number {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: 0.05em;
  color: #171b34;
}
.eticket-number .muted-label { display: block; font-family: inherit; font-weight: 600; font-size: 0.65rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-muted); margin-bottom: 2px; }

.eticket-trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(28,154,108,0.1);
  color: #157e58;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  margin-top: 4px;
}

.eticket-id {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.68rem;
  color: rgba(255,255,255,0.75);
  letter-spacing: 0.02em;
  word-break: break-all;
}

.share-row { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0; }
.share-row .btn { white-space: nowrap; }

.tabs { display: flex; gap: 8px; margin-bottom: 20px; border-bottom: 1px solid var(--border); }
.tabs a { padding: 10px 16px; color: var(--text-muted); position: relative; transition: color 0.15s ease; }
.tabs a.active { color: var(--text); }
.tabs a.active::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -1px;
  height: 2px;
  background: var(--primary);
  border-radius: 2px;
  animation: tabIn 0.25s var(--ease) both;
}
@keyframes tabIn {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

.admin-layout { display: flex; min-height: 100vh; }
.admin-sidebar {
  width: 220px;
  background: var(--bg-soft);
  border-right: 1px solid var(--border);
  padding: 24px 20px;
  flex-shrink: 0;
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}
.admin-sidebar a { display: block; padding: 8px 0; color: var(--text-muted); transition: color 0.15s ease, transform 0.15s ease; }
.admin-sidebar a.active, .admin-sidebar a:hover { color: var(--primary); transform: translateX(3px); }
.admin-content { flex: 1; min-width: 0; padding: 32px; max-width: 1200px; }

/* En dessous de 780px, la sidebar fixe (220px) + le contenu ne tiennent plus
   côte à côte sans déborder horizontalement : on empile la sidebar au-dessus
   du contenu à la place. */
@media (max-width: 780px) {
  .admin-layout { flex-direction: column; }
  .admin-sidebar { width: 100%; height: auto; position: static; border-right: none; border-bottom: 1px solid var(--border); }
  .admin-content { padding: 20px; }
}

.page-head {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 28px;
}
.page-head .page-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), #ff9a4d);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.3rem;
  flex-shrink: 0;
  box-shadow: var(--shadow-primary);
}
.page-head h1 { margin: 0; }
.page-head p { margin: 2px 0 0; color: var(--text-muted); font-size: 0.9rem; }

.stat-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; margin-bottom: 32px; }
.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-top: 3px solid var(--stat-color, var(--primary));
  border-radius: var(--radius);
  padding: 18px;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
  animation: cardIn 0.45s var(--ease) both;
  display: flex;
  align-items: flex-start;
  gap: 14px;
}
.stat-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.stat-card .stat-icon {
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: color-mix(in srgb, var(--stat-color, var(--primary)) 14%, transparent);
  color: var(--stat-color, var(--primary));
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  flex-shrink: 0;
}
.stat-card .value { font-size: 1.5rem; font-weight: 700; line-height: 1.2; }
.stat-card .label { color: var(--text-muted); font-size: 0.82rem; margin-top: 2px; }
.stat-card:nth-of-type(4n+1) { --stat-color: #f2711c; }
.stat-card:nth-of-type(4n+2) { --stat-color: #1c9a6c; }
.stat-card:nth-of-type(4n+3) { --stat-color: #0984e3; }
.stat-card:nth-of-type(4n+4) { --stat-color: #a259e6; }

.table-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-sm);
  overflow: hidden;
  margin-bottom: 20px;
}
.table-card table { margin: 0; }
.table-card th { background: var(--bg); }

.avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), #ff9a4d);
  color: #fff;
  font-size: 0.78rem;
  font-weight: 700;
  flex-shrink: 0;
}
.user-row { display: flex; align-items: center; gap: 10px; }

.select-inline {
  padding: 6px 10px;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg-soft);
  color: var(--text);
  font-size: 0.85rem;
  font-family: inherit;
  transition: border-color 0.15s ease;
}
.select-inline:focus { outline: none; border-color: var(--primary); }

.dispute-list { display: flex; flex-direction: column; gap: 14px; }
.dispute-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-left: 4px solid var(--dispute-color, var(--warning));
  border-radius: var(--radius);
  padding: 16px 18px;
  box-shadow: var(--shadow-sm);
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  animation: cardIn 0.4s var(--ease) both;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}
.dispute-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.dispute-card.status-open { --dispute-color: #c98a06; }
.dispute-card.status-resolved { --dispute-color: #1c9a6c; }
.dispute-card.status-rejected { --dispute-color: var(--text-muted); }
.dispute-card .dispute-reason { font-weight: 600; margin: 0 0 4px; }
.dispute-card .dispute-meta { font-size: 0.8rem; color: var(--text-muted); }
.dispute-card .dispute-actions { display: flex; gap: 8px; flex-wrap: wrap; }

#scan-reader { width: 100%; max-width: 420px; border-radius: 8px; overflow: hidden; }
.scan-result { padding: 20px; border-radius: 8px; font-size: 1.1rem; font-weight: 600; text-align: center; margin-top: 16px; animation: alertIn 0.3s var(--ease) both; }
.scan-result.accepted { background: rgba(28,154,108,0.1); color: #157e58; }
.scan-result.rejected { background: rgba(224,72,60,0.1); color: #b5342a; }
.scan-result.unpaid { background: rgba(201,138,6,0.1); color: #8a6205; }

.site-footer { margin-top: 48px; background: var(--bg-soft); border-top: 1px solid var(--border); }
.footer-grid {
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr 1fr;
  gap: 32px;
  padding: 48px 20px 32px;
}
@media (max-width: 800px) { .footer-grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 480px) { .footer-grid { grid-template-columns: 1fr; } }

.footer-logo { height: 34px; width: auto; margin-bottom: 12px; }
.footer-brand p { max-width: 280px; font-size: 0.85rem; margin: 0; }

.footer-col { display: flex; flex-direction: column; gap: 10px; font-size: 0.9rem; }
.footer-col h3 {
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  margin: 0 0 4px;
  font-weight: 700;
}
.footer-col a { color: var(--text); transition: color 0.15s ease, transform 0.15s ease; display: inline-block; width: fit-content; }
.footer-col a:hover { color: var(--primary); transform: translateX(2px); }

.footer-bottom { border-top: 1px solid var(--border); }
.footer-bottom-inner {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 16px 20px;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.admin-brand { display: block; margin-bottom: 2px; }
.admin-brand .brand-logo { height: 40px; }
.admin-tag {
  display: block;
  font-size: 0.68rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
  margin: 0 0 24px;
}

/* Impression propre d'un billet (distribution papier) : on ne garde que le billet.
   Les éléments à masquer portent la classe .no-print (voir wallet/show.php). */
@media print {
  .no-print { display: none !important; }
  body { background: #fff; }
  .eticket-stub { box-shadow: none; border: 1px solid #ccc; }
  .main { padding: 0; }
  .grid-2 { display: block; }
}

/* Impression groupée : on réutilise EXACTEMENT la forme du billet du
   portefeuille (.eticket-stub — photo + talon QR blanc perforé), en version
   resserrée (.print-eticket) pour faire tenir une dizaine de billets sur une
   feuille A4 au lieu d'une page entière par billet. */
.print-batch-list { display: flex; flex-direction: column; gap: 10px; }

.print-eticket { break-inside: avoid; page-break-inside: avoid; animation: none; }
.print-eticket .eticket-stub-main.photo-only { min-height: 92px; }
.print-eticket .eticket-stub-content { padding: 8px 14px; gap: 6px; }
.print-eticket .eticket-brand-mini { padding: 3px 10px 3px 4px; gap: 5px; font-size: 0.7rem; }
.print-eticket .eticket-brand-mini img { height: 16px; width: 16px; }
.print-eticket .eticket-stub-title { font-size: 0.95rem; }
.print-eticket .eticket-stub-sub { font-size: 0.68rem; gap: 4px; }
.print-eticket .eticket-pill { padding: 3px 8px; font-size: 0.62rem; }

.print-eticket .eticket-stub-side { min-width: 120px; padding: 8px; gap: 3px; }
.print-eticket .eticket-stub-brand { font-size: 0.72rem; }
.print-eticket .eticket-stub-brand img { height: 15px; width: 15px; }
.print-eticket .eticket-scan-label { font-size: 0.55rem; }
.print-eticket .eticket-number { font-size: 0.72rem; }
.print-eticket .eticket-number .muted-label { font-size: 0.52rem; }
.print-eticket .eticket-trust-badge { font-size: 0.56rem; padding: 3px 8px; margin-top: 2px; }

.print-ticket-qrcode { padding: 6px; }
.print-ticket-qrcode canvas, .print-ticket-qrcode img { display: block; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}
