:root {
  /* --- Aurgarde : palette --- */
  --bg: #050816;
  --bg-secondary: #090e1d;
  --bg-surface: rgba(15, 23, 42, 0.72);
  --bg-card: rgba(18, 27, 48, 0.78);
  --bg-card-hover: rgba(24, 37, 65, 0.92);
  --border: rgba(148, 163, 184, 0.13);
  --border-active: rgba(0, 194, 255, 0.55);

  --blue: #008cff;
  --cyan: #00d9ff;
  --blue-premium: #2563ff;
  --violet: #7657ff;
  --success: #32d583;
  --warning: #ff9f43;
  --danger: #ff5c7c;

  --text: #f8fafc;
  --text-muted: #aab6cf;
  --text-dim: #69758d;

  --gradient-premium: linear-gradient(135deg, #00d9ff 0%, #2563ff 52%, #7657ff 100%);
  --gradient-cta: linear-gradient(135deg, #008cff 0%, #00d9ff 100%);

  /* Alias rétro-compatibles : tout le CSS existant qui référence ces noms
     hérite automatiquement de la nouvelle palette, sans avoir à toucher
     chaque règle une par une. */
  --accent: var(--blue);
  --accent-hover: var(--cyan);
  --bg-elevated: var(--bg-secondary);

  --radius: 16px;
  --radius-sm: 10px;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --font-heading: "Space Grotesk", "Sora", "Inter", -apple-system, sans-serif;
  --font-body: "Inter", -apple-system, "Segoe UI", Roboto, Arial, sans-serif;

  --sidebar-width: 288px;
  --sidebar-width-collapsed: 76px;
  --topbar-height: 62px;
}

* { box-sizing: border-box; }

/* Scrollbar de la fenêtre elle-même (là où défile le contenu principal, à
   droite) — même DA que la scrollbar de la sidebar (voir .sidebar plus bas),
   plutôt que la barre blanche par défaut du navigateur. */
html {
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
html::-webkit-scrollbar { width: 6px; }
html::-webkit-scrollbar-track { background: transparent; }
html::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }
html::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }

body {
  font-family: var(--font-body);
  background:
    radial-gradient(circle at 15% 10%, rgba(0, 140, 255, 0.12), transparent 35%),
    radial-gradient(circle at 85% 15%, rgba(118, 87, 255, 0.10), transparent 32%),
    radial-gradient(circle at 50% 100%, rgba(0, 217, 255, 0.06), transparent 40%),
    var(--bg);
  background-attachment: fixed;
  color: var(--text);
  margin: 0;
  line-height: 1.5;
}

a { color: var(--cyan); text-decoration: none; }
a:hover { color: var(--blue); }

h1, h2, h3 { font-family: var(--font-heading); color: var(--text); }
h1 { font-size: 2rem; font-weight: 700; margin: 0 0 0.35rem; letter-spacing: -0.01em; }
h2 { font-size: 1.3rem; font-weight: 600; margin: 0 0 0.5rem; letter-spacing: -0.01em; }
h3 { font-size: 1.05rem; font-weight: 600; margin: 0; }
p { color: var(--text-muted); margin: 0; }
code {
  background: rgba(148, 163, 184, 0.12);
  border: 1px solid var(--border);
  border-radius: 5px;
  padding: 0.1rem 0.4rem;
  font-size: 0.85em;
}

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

/* ==================================================
   Sidebar
   ================================================== */
.sidebar {
  position: fixed;
  top: 0; left: 0; bottom: 0;
  width: var(--sidebar-width);
  background: var(--bg-secondary);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 1.25rem 0.9rem;
  z-index: 40;
  transition: width 0.22s var(--ease), transform 0.22s var(--ease);
  overflow-y: auto;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}
.sidebar::-webkit-scrollbar { width: 6px; }
.sidebar::-webkit-scrollbar-track { background: transparent; }
.sidebar::-webkit-scrollbar-thumb { background: var(--border); border-radius: 999px; }
.sidebar::-webkit-scrollbar-thumb:hover { background: var(--text-dim); }
.sidebar-brand {
  display: flex; align-items: center; gap: 0.6rem;
  font-family: var(--font-heading); font-weight: 700; font-size: 1.1rem; color: var(--text);
  text-decoration: none; padding: 0.4rem 0.6rem 1.3rem;
}
.sidebar-brand:hover { color: var(--text); }
.sidebar-brand-logo {
  width: 28px; height: 28px; border-radius: 50%;
  box-shadow: 0 0 12px rgba(0, 217, 255, 0.45);
  flex-shrink: 0;
  object-fit: cover;
}
.sidebar-brand-text { white-space: nowrap; overflow: hidden; }

.sidebar-group { margin-bottom: 1.4rem; }
.sidebar-group-title {
  font-size: 0.7rem; text-transform: uppercase; letter-spacing: 0.08em;
  color: var(--text-dim); font-weight: 700; padding: 0 0.6rem; margin-bottom: 0.5rem;
  white-space: nowrap; overflow: hidden;
}
.sidebar-link {
  display: flex; align-items: center; gap: 0.75rem;
  padding: 0.55rem 0.6rem; border-radius: var(--radius-sm);
  color: var(--text-muted); font-size: 0.88rem; font-weight: 600;
  margin-bottom: 0.15rem; white-space: nowrap; overflow: hidden;
  border: 1px solid transparent;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease);
}
.sidebar-link svg { flex-shrink: 0; color: var(--text-dim); transition: color 0.18s var(--ease); }
.sidebar-link:hover { background: var(--bg-card); color: var(--text); }
.sidebar-link:hover svg { color: var(--cyan); }
.sidebar-link.is-active {
  background: rgba(0, 140, 255, 0.12);
  border-color: var(--border-active);
  color: var(--text);
  box-shadow: 0 0 16px rgba(0, 140, 255, 0.15);
}
.sidebar-link.is-active svg { color: var(--cyan); }
.sidebar-link-text { overflow: hidden; text-overflow: ellipsis; }

.sidebar-collapse-btn {
  margin-top: auto; display: flex; align-items: center; gap: 0.6rem;
  background: none; border: 1px solid var(--border); color: var(--text-dim);
  border-radius: var(--radius-sm); padding: 0.55rem 0.6rem; cursor: pointer;
  font-size: 0.8rem; font-family: inherit; white-space: nowrap; overflow: hidden;
}
.sidebar-collapse-btn:hover { color: var(--text); border-color: var(--border-active); }
.sidebar-collapse-btn svg { flex-shrink: 0; transition: transform 0.22s var(--ease); }
.sidebar-legal-links { display: flex; flex-direction: column; gap: 0.3rem; padding: 0 0.6rem 0.7rem; }
.sidebar-legal-links a { font-size: 0.72rem; color: var(--text-dim); text-decoration: none; }
.sidebar-legal-links a:hover { color: var(--text-muted); text-decoration: underline; }

body.sidebar-collapsed .sidebar { width: var(--sidebar-width-collapsed); }
body.sidebar-collapsed .sidebar-brand-text,
body.sidebar-collapsed .sidebar-group-title,
body.sidebar-collapsed .sidebar-link-text,
body.sidebar-collapsed .sidebar-legal-links,
body.sidebar-collapsed .sidebar-collapse-btn span { display: none; }
body.sidebar-collapsed .sidebar-collapse-btn svg { transform: rotate(180deg); }
body.sidebar-collapsed .page,
body.sidebar-collapsed .topbar-slim { margin-left: var(--sidebar-width-collapsed); }

.sidebar-overlay { display: none; }

@media (max-width: 880px) {
  .sidebar { transform: translateX(-100%); box-shadow: 0 0 40px rgba(0,0,0,0.5); }
  body.sidebar-mobile-open .sidebar { transform: translateX(0); }
  body.sidebar-collapsed .page,
  .page, .topbar-slim { margin-left: 0 !important; }
  body.sidebar-mobile-open .sidebar-overlay {
    display: block; position: fixed; inset: 0; background: rgba(2, 5, 15, 0.6);
    z-index: 35; backdrop-filter: blur(2px);
  }
  .sidebar-mobile-toggle { display: inline-flex !important; }
}

/* ==================================================
   Topbar (fine, au-dessus du contenu)
   ================================================== */
.topbar-slim {
  margin-left: var(--sidebar-width); transition: margin-left 0.22s var(--ease);
  position: sticky; top: 0; z-index: 30;
  display: flex; align-items: center; gap: 1rem;
  padding: 0 1.5rem; height: var(--topbar-height);
  background: rgba(5, 8, 22, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--border);
}
.sidebar-mobile-toggle {
  display: none; background: none; border: 1px solid var(--border); color: var(--text);
  border-radius: var(--radius-sm); width: 34px; height: 34px; align-items: center; justify-content: center;
  cursor: pointer; flex-shrink: 0;
}
.topbar-crumbs { font-size: 0.85rem; color: var(--text-muted); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.topbar-crumbs a { color: var(--text-muted); }
.topbar-crumbs a:hover { color: var(--cyan); }

.status-pill {
  display: flex; align-items: center; gap: 0.4rem;
  font-size: 0.76rem; font-weight: 600; color: var(--text-dim);
  border: 1px solid var(--border); border-radius: 999px; padding: 0.28rem 0.65rem 0.28rem 0.5rem;
  flex-shrink: 0;
}
.status-pill .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--text-dim); }
.status-pill .dot.is-online { background: var(--success); box-shadow: 0 0 8px rgba(50, 213, 131, 0.7); }
.status-pill .dot.is-offline { background: var(--danger); box-shadow: 0 0 8px rgba(255, 92, 124, 0.7); }

.topbar-right { display: flex; align-items: center; gap: 0.7rem; margin-left: auto; flex-shrink: 0; }

.lang-switch { display: flex; gap: 0.2rem; font-size: 0.76rem; font-weight: 700; }
.lang-switch a { color: var(--text-dim); padding: 0.28rem 0.55rem; border-radius: 6px; }
.lang-switch a:hover { color: var(--text); background: var(--bg-card-hover); }
.lang-switch a.is-active { color: var(--text); background: var(--bg-card); border: 1px solid var(--border); }

/* Menu profil */
.profile-menu { position: relative; }
.profile-trigger {
  display: flex; align-items: center; gap: 0.5rem; background: none; border: 1px solid transparent;
  padding: 0.25rem 0.5rem 0.25rem 0.25rem; border-radius: 999px; cursor: pointer; color: var(--text);
  font-family: inherit; font-size: 0.85rem; font-weight: 600;
}
.profile-trigger:hover { background: var(--bg-card); border-color: var(--border); }
.profile-trigger img { width: 30px; height: 30px; border-radius: 50%; }
.profile-trigger svg { color: var(--text-dim); }
.profile-dropdown {
  position: absolute; right: 0; top: calc(100% + 0.5rem); min-width: 200px;
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-sm);
  box-shadow: 0 12px 32px rgba(0,0,0,0.45);
  padding: 0.4rem; display: none; flex-direction: column; gap: 0.1rem; z-index: 50;
}
.profile-menu.is-open .profile-dropdown { display: flex; }
.profile-dropdown a, .profile-dropdown button {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.5rem 0.6rem; border-radius: 7px;
  color: var(--text-muted); font-size: 0.85rem; font-weight: 500; text-align: left;
  background: none; border: none; width: 100%; cursor: pointer; font-family: inherit;
}
.profile-dropdown a:hover, .profile-dropdown button:hover { background: var(--bg-card); color: var(--text); }
.profile-dropdown svg { color: var(--text-dim); flex-shrink: 0; }
.profile-dropdown hr { border: none; border-top: 1px solid var(--border); margin: 0.3rem 0; }
.profile-dropdown .is-danger { color: var(--danger); }
.profile-dropdown .is-danger svg { color: var(--danger); }

/* ==================================================
   Layout général
   ================================================== */
.page {
  max-width: 1080px; margin-left: var(--sidebar-width); margin-right: auto;
  padding: 2.25rem 2rem 4rem; animation: page-in 0.32s var(--ease);
  transition: margin-left 0.22s var(--ease);
}
/* Pages avec un tableau large (ex: comparatif Premium) — laisse le contenu
   respirer sur les écrans larges au lieu de forcer un défilement horizontal
   prématuré ; le défilement du tableau lui-même (overflow-x: auto) reste le
   filet de sécurité si trop de formules sont ajoutées un jour. */
.page.page-wide { max-width: 1400px; }
@keyframes page-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.page-header { margin-bottom: 1.9rem; }
.section { margin-bottom: 2.25rem; }
.section-title { font-size: 0.76rem; text-transform: uppercase; letter-spacing: 0.08em; color: var(--text-dim); font-weight: 700; margin-bottom: 0.9rem; }

/* ==================================================
   Cartes
   ================================================== */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
  box-shadow: 0 1px 0 rgba(255,255,255,0.03) inset, 0 12px 28px rgba(0,0,0,0.18);
}
.card + .card { margin-top: 1rem; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); gap: 1rem; }

/* Panels de tickets : chaque panel affiche désormais son embed + toute la
   liste de ses catégories + ses actions (bien plus dense qu'une simple carte
   de fonctionnalité) — une pile pleine largeur plutôt que la grille de
   colonnes de 290px, qui écrasait ce contenu et cassait les badges/boutons. */
.panels-stack { display: flex; flex-direction: column; gap: 1.25rem; }
.panel-card { max-width: 640px; }
.panel-actions { flex-wrap: wrap; }
.panel-actions .btn { display: inline-flex; align-items: center; gap: 0.35rem; white-space: nowrap; }

.feature-card {
  position: relative;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.2rem 1.3rem;
  display: flex;
  align-items: flex-start;
  gap: 0.9rem;
  transition: transform 0.2s var(--ease), background 0.2s var(--ease), border-color 0.2s var(--ease), box-shadow 0.2s var(--ease);
  animation: card-in 0.32s var(--ease) backwards;
}
@keyframes card-in { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.feature-card:hover {
  background: var(--bg-card-hover);
  border-color: var(--border-active);
  transform: translateY(-2px);
  box-shadow: 0 0 0 1px rgba(0, 194, 255, 0.12), 0 16px 32px rgba(0, 20, 60, 0.35);
}
.feature-card.is-configured { border-color: rgba(0, 217, 255, 0.28); }
.feature-card .icon-square {
  width: 42px; height: 42px; border-radius: 12px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(0, 140, 255, 0.22), rgba(118, 87, 255, 0.22));
  border: 1px solid rgba(0, 194, 255, 0.2);
  color: var(--cyan);
}
.feature-card .icon { font-size: 1.5rem; line-height: 1; margin-top: 0.1rem; }
.feature-card .body { flex: 1; min-width: 0; }
.feature-card .body a.title { display: block; font-weight: 600; color: var(--text); margin-bottom: 0.3rem; font-family: var(--font-heading); }
.feature-card .body a.title:hover { color: var(--cyan); }
.feature-card .body .desc {
  font-size: 0.83rem; color: var(--text-muted); line-height: 1.45;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
  overflow: hidden; min-height: 2.4em;
}
.feature-card .body .card-meta { display: flex; align-items: center; justify-content: space-between; gap: 0.5rem; margin-top: 0.7rem; flex-wrap: wrap; min-height: 1.4rem; }
.feature-card .toggle-form { flex-shrink: 0; }
.feature-card.is-off { opacity: 0.62; }
.feature-card.is-hidden-by-filter { display: none; }

/* Badge Premium + interrupteur empilés verticalement, en flux normal (pas de
   position absolue) — évite tout chevauchement entre les deux quelle que
   soit la largeur du badge. */
.card-corner { display: flex; flex-direction: column; align-items: flex-end; gap: 0.55rem; flex-shrink: 0; }

.configure-link {
  display: inline-flex; align-items: center; gap: 0.2rem;
  font-size: 0.76rem; font-weight: 600; color: var(--cyan);
  opacity: 0; transform: translateX(-4px);
  transition: opacity 0.18s var(--ease), transform 0.18s var(--ease);
}
.feature-card:hover .configure-link { opacity: 1; transform: none; }
.configure-link svg { transition: transform 0.18s var(--ease); }
.configure-link:hover svg { transform: translateX(2px); }

/* Formulaire d'édition repliable (panels/catégories de tickets, profils de
   salons vocaux temporaires...) — évite de dupliquer une page entière juste
   pour éditer une ligne déjà créée. */
.edit-details { margin-top: 0.6rem; }
.edit-details summary { cursor: pointer; font-size: 0.8rem; font-weight: 600; color: var(--cyan); list-style: none; }
.edit-details summary::-webkit-details-marker { display: none; }
.edit-details[open] summary { margin-bottom: 0.7rem; }
.edit-details .card-inset { background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-sm); padding: 1rem; }

/* ==================================================
   Documentation (/documentation)
   ================================================== */
.docs-nav {
  display: flex; flex-wrap: wrap; gap: 0.5rem;
  margin-bottom: 1.6rem; position: sticky; top: 0.5rem; z-index: 5;
}
.docs-nav-chip { text-decoration: none; display: inline-flex; align-items: center; gap: 0.4rem; }

.doc-category { scroll-margin-top: 1rem; }
.doc-article-list { display: flex; flex-direction: column; gap: 0.7rem; }

.doc-article {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1rem 1.2rem; transition: border-color 0.18s var(--ease);
}
.doc-article[open] { border-color: var(--border-active); }
.doc-article summary {
  list-style: none; cursor: pointer;
  display: flex; align-items: center; gap: 0.9rem;
}
.doc-article summary::-webkit-details-marker { display: none; }
.doc-article-icon { flex-shrink: 0; }
.doc-article-heading { flex: 1; min-width: 0; }
.doc-article-title { display: block; font-weight: 600; font-family: var(--font-heading); color: var(--text); }
.doc-article-teaser {
  display: block; font-size: 0.83rem; color: var(--text-muted); margin-top: 0.2rem;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.doc-article-caret { flex-shrink: 0; color: var(--text-dim); transition: transform 0.18s var(--ease); }
.doc-article[open] .doc-article-caret { transform: rotate(180deg); }

.doc-article-body { margin-top: 1rem; padding-top: 1rem; border-top: 1px solid var(--border); }
.doc-block { margin-bottom: 1rem; }
.doc-block:last-child { margin-bottom: 0; }
.doc-block h4 {
  font-size: 0.72rem; text-transform: uppercase; letter-spacing: 0.06em;
  color: var(--cyan); font-weight: 700; margin-bottom: 0.5rem;
  display: flex; align-items: center; gap: 0.3rem;
}
.doc-block p { color: var(--text-muted); line-height: 1.55; }
.doc-block ul, .doc-block ol { padding-left: 1.2rem; color: var(--text-muted); line-height: 1.65; }
.doc-block li { margin-bottom: 0.3rem; }
.doc-block-tips {
  background: rgba(118, 87, 255, 0.08); border: 1px solid rgba(118, 87, 255, 0.2);
  border-radius: var(--radius-sm); padding: 0.85rem 1rem;
}
.doc-block-tips h4 { color: var(--violet); }

.config-status { display: inline-flex; align-items: center; gap: 0.35rem; font-size: 0.72rem; font-weight: 600; color: var(--text-dim); }
.config-status svg { width: 13px; height: 13px; }
.config-status.is-configured { color: var(--success); }

/* ==================================================
   Badges
   ================================================== */
.badge {
  display: inline-flex; align-items: center; gap: 0.3rem;
  font-size: 0.68rem; font-weight: 700; padding: 0.2rem 0.55rem; border-radius: 999px;
  background: rgba(148, 163, 184, 0.14); color: var(--text-muted);
  text-transform: uppercase; letter-spacing: 0.03em;
}
.badge.badge-free { background: rgba(148, 163, 184, 0.14); color: var(--text-muted); }
.badge.badge-premium {
  background: var(--gradient-premium); color: white;
  box-shadow: 0 0 14px rgba(118, 87, 255, 0.35);
}
.badge.badge-active { background: rgba(50, 213, 131, 0.15); color: var(--success); }
.badge.badge-pending { background: rgba(255, 159, 67, 0.15); color: var(--warning); }
.badge.badge-dismissed { background: rgba(148, 163, 184, 0.14); color: var(--text-dim); }
.badge.badge-new { background: rgba(0, 217, 255, 0.15); color: var(--cyan); }
.badge.badge-promo { background: var(--gradient-premium); color: white; box-shadow: 0 0 14px rgba(118, 87, 255, 0.35); }

/* ==================================================
   Barre de statistiques (Centre de fonctionnalités)
   ================================================== */
.stats-bar { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 0.85rem; margin-bottom: 1.5rem; }
.stat-tile {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1rem 1.1rem;
}
.stat-tile .stat-value { font-family: var(--font-heading); font-size: 1.6rem; font-weight: 700; color: var(--text); }
.stat-tile .stat-value.accent { background: var(--gradient-cta); -webkit-background-clip: text; background-clip: text; color: transparent; }
.stat-tile .stat-label { font-size: 0.76rem; color: var(--text-dim); margin-top: 0.2rem; }

/* Filtres rapides */
.filter-bar { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-bottom: 1.4rem; }
.filter-chip {
  background: var(--bg-card); border: 1px solid var(--border); color: var(--text-muted);
  border-radius: 999px; padding: 0.4rem 0.95rem; font-size: 0.8rem; font-weight: 600;
  cursor: pointer; font-family: inherit; transition: all 0.18s var(--ease);
}
.filter-chip:hover { color: var(--text); border-color: var(--border-active); }
.filter-chip.is-active { background: var(--gradient-cta); color: white; border-color: transparent; }

/* ==================================================
   Interrupteur
   ================================================== */
.switch { position: relative; display: inline-block; width: 42px; height: 24px; flex-shrink: 0; }
.switch input { opacity: 0; width: 0; height: 0; }
.switch .slider {
  position: absolute; cursor: pointer; inset: 0;
  background: rgba(148, 163, 184, 0.25); border-radius: 999px; transition: background 0.2s var(--ease);
}
.switch .slider::before {
  content: ""; position: absolute; height: 18px; width: 18px; left: 3px; top: 3px;
  background: white; border-radius: 50%; transition: transform 0.2s var(--ease);
  box-shadow: 0 2px 6px rgba(0,0,0,0.3);
}
.switch input:checked + .slider { background: var(--gradient-cta); box-shadow: 0 0 10px rgba(0, 217, 255, 0.4); }
.switch input:checked + .slider::before { transform: translateX(18px); }

/* ==================================================
   Boutons
   ================================================== */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  background: var(--gradient-cta);
  color: white;
  padding: 0.62rem 1.3rem;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  text-decoration: none;
  font-size: 0.88rem;
  font-family: inherit;
  font-weight: 600;
  transition: filter 0.18s var(--ease), transform 0.18s var(--ease), box-shadow 0.18s var(--ease);
  box-shadow: 0 4px 16px rgba(0, 140, 255, 0.25);
}
.btn:hover { filter: brightness(1.1); color: white; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }
.btn.danger { background: var(--danger); box-shadow: 0 4px 16px rgba(255, 92, 124, 0.25); }
.btn.danger:hover { filter: brightness(1.08); }
.btn.secondary { background: transparent; border: 1px solid var(--border); color: var(--text); box-shadow: none; }
.btn.secondary:hover { background: var(--bg-card-hover); color: var(--text); border-color: var(--border-active); }
.btn.small { padding: 0.42rem 0.85rem; font-size: 0.8rem; }

/* ==================================================
   Formulaires
   ================================================== */
.field { margin-bottom: 1.15rem; }
.field:last-child { margin-bottom: 0; }
label { display: block; font-size: 0.82rem; font-weight: 600; color: var(--text); margin-bottom: 0.35rem; }
.field-hint { display: block; font-size: 0.76rem; color: var(--text-dim); margin-top: 0.3rem; }
input[type=text], input[type=number], textarea, select {
  width: 100%;
  padding: 0.6rem 0.75rem;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
  background: var(--bg-surface);
  color: var(--text);
  font-family: inherit;
  font-size: 0.9rem;
  transition: border-color 0.15s var(--ease), box-shadow 0.15s var(--ease);
}
input[type=text]:focus, input[type=number]:focus, textarea:focus, select:focus {
  outline: none; border-color: var(--cyan); box-shadow: 0 0 0 3px rgba(0, 217, 255, 0.15);
}
input::placeholder, textarea::placeholder { color: var(--text-dim); }
textarea { min-height: 76px; resize: vertical; }
.color-field { display: flex; align-items: center; gap: 0.6rem; }
.color-field input[type=color] { width: 42px; height: 38px; padding: 2px; border-radius: var(--radius-sm); border: 1px solid var(--border); background: var(--bg-surface); cursor: pointer; }
.color-field input[type=text] { flex: 1; }
.checkbox-field { display: flex; align-items: center; gap: 0.55rem; }
.checkbox-field input { width: 17px; height: 17px; accent-color: var(--blue); }
.checkbox-field label { margin: 0; }

.form-actions { margin-top: 1.5rem; display: flex; gap: 0.6rem; align-items: center; }
.unsaved-indicator {
  font-size: 0.78rem; color: var(--warning); font-weight: 600; display: none; align-items: center; gap: 0.35rem;
}
.unsaved-indicator.is-visible { display: inline-flex; }

/* ==================================================
   Divers
   ================================================== */
.error { background: rgba(255, 92, 124, 0.1); border: 1px solid rgba(255, 92, 124, 0.3); color: #ffb0c1; padding: 0.75rem 1rem; border-radius: var(--radius-sm); margin-bottom: 1.25rem; font-size: 0.88rem; }
.guild-icon { width: 40px; height: 40px; border-radius: 50%; }
.guild-list-item { display: flex; align-items: center; gap: 0.85rem; }
.guild-list-item .name { font-weight: 600; }

table { width: 100%; border-collapse: collapse; }
th { text-align: left; padding: 0.65rem 0.75rem; font-size: 0.74rem; text-transform: uppercase; letter-spacing: 0.05em; color: var(--text-dim); border-bottom: 1px solid var(--border); }
td { padding: 0.7rem 0.75rem; border-bottom: 1px solid var(--border); font-size: 0.88rem; color: var(--text); }
tr:last-child td { border-bottom: none; }

.login-shell {
  min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 2rem;
  background:
    radial-gradient(circle at 20% 20%, rgba(0, 140, 255, 0.16), transparent 40%),
    radial-gradient(circle at 80% 80%, rgba(118, 87, 255, 0.14), transparent 40%),
    var(--bg);
}
.login-card {
  max-width: 400px; width: 100%; text-align: center;
  border-radius: 20px;
  box-shadow: 0 24px 60px rgba(0, 20, 60, 0.4);
}
.login-card .logo { font-size: 2.5rem; margin-bottom: 0.75rem; }

.empty-state { text-align: center; padding: 2rem 1rem; color: var(--text-dim); font-size: 0.9rem; }
.search-field { position: relative; }
.search-field svg { position: absolute; left: 1.1rem; top: 50%; transform: translateY(-50%); color: var(--text-dim); pointer-events: none; width: 20px; height: 20px; }
/* input[type=text] (0,1,1) est plus spécifique que .feature-search seule (0,1,0)
   et gagnait sur son padding — on égalise la spécificité pour que celui-ci
   s'applique (sinon le texte démarre sous l'icône loupe). */
input[type=text].feature-search { font-size: 1.02rem; padding: 0.95rem 1.2rem 0.95rem 3.1rem; }

/* --- Sélecteurs Discord (salons/rôles) --- */
select option { background: var(--bg-secondary); color: var(--text); }

.checklist-field { border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg-surface); overflow: hidden; }
.checklist-search {
  width: 100%; padding: 0.6rem 0.75rem; border: none; border-bottom: 1px solid var(--border);
  background: var(--bg-secondary); color: var(--text); font-family: inherit; font-size: 0.85rem;
}
.checklist-search:focus { outline: none; }
.checklist-options { max-height: 220px; overflow-y: auto; padding: 0.4rem; }
.checklist-option { display: flex; align-items: center; gap: 0.5rem; padding: 0.4rem 0.5rem; border-radius: 5px; font-size: 0.87rem; cursor: pointer; }
.checklist-option:hover { background: var(--bg-card-hover); }
.checklist-option input { width: 15px; height: 15px; accent-color: var(--blue); flex-shrink: 0; }
.checklist-option.is-hidden { display: none; }
.checklist-option.is-disabled { opacity: 0.5; cursor: not-allowed; }
.checklist-option.is-disabled:hover { background: none; }
.checklist-empty { padding: 0.6rem; color: var(--text-dim); font-size: 0.85rem; }

/* --- Aperçu d'embed Discord --- */
.discord-embed-preview {
  background: #2b2d31;
  border-left: 4px solid #2b2d31;
  border-radius: 4px;
  padding: 0.7rem 0.9rem;
  max-width: 480px;
  font-size: 0.875rem;
  color: #dbdee1;
}
.discord-embed-preview .embed-thumb { float: right; width: 64px; height: 64px; border-radius: 4px; object-fit: cover; margin-left: 0.75rem; }
.discord-embed-preview .embed-author { font-weight: 600; color: #fff; margin-bottom: 0.3rem; }
.discord-embed-preview .embed-title { font-weight: 700; color: #fff; margin-bottom: 0.3rem; white-space: pre-wrap; }
.discord-embed-preview .embed-description { color: #dbdee1; white-space: pre-wrap; margin-bottom: 0.4rem; }
.discord-embed-preview .embed-fields { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0.4rem 0; }
.discord-embed-preview .embed-field { flex: 1 1 100%; }
.discord-embed-preview .embed-field.is-inline { flex: 1 1 calc(33% - 0.6rem); min-width: 100px; }
.discord-embed-preview .embed-field-name { font-weight: 700; color: #fff; font-size: 0.85rem; margin-bottom: 0.15rem; }
.discord-embed-preview .embed-field-value { color: #dbdee1; white-space: pre-wrap; }
.discord-embed-preview .embed-image { display: block; max-width: 100%; border-radius: 4px; margin-top: 0.5rem; }
.discord-embed-preview .embed-footer { color: #949ba4; font-size: 0.75rem; margin-top: 0.5rem; clear: both; }
.discord-embed-preview .embed-empty { color: #6d7178; font-size: 0.8rem; font-style: italic; }

/* --- Glisser-déposer --- */
.drag-list { display: flex; flex-direction: column; gap: 0.35rem; }
.drag-item {
  display: flex; align-items: center; gap: 0.7rem; padding: 0.6rem 0.8rem;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm); cursor: grab;
}
.drag-item.is-dragging { opacity: 0.4; }
.drag-handle { color: var(--text-dim); font-size: 1.1rem; user-select: none; }
.drag-item-body { flex: 1; min-width: 0; }
.drag-item-title { font-weight: 600; font-size: 0.9rem; }
.drag-item-desc { font-size: 0.78rem; color: var(--text-muted); }
/* Variante pour un contenu vertical plus riche (ex: carte de formule tarifaire
   éditable) plutôt que la ligne compacte par défaut. */
.drag-item.drag-item-block { display: block; }
.drag-item.drag-item-block .drag-handle { display: inline-block; margin-bottom: 0.6rem; }

/* --- Liste salon + message à conserver (nettoyage périodique) --- */
.channel-message-list { display: flex; flex-direction: column; gap: 0.5rem; }
.channel-message-rows { display: flex; flex-direction: column; gap: 0.5rem; }
.channel-message-row {
  display: flex; align-items: center; gap: 0.6rem; padding: 0.6rem 0.7rem;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.channel-message-row .cm-channel { flex: 1; min-width: 0; }
.channel-message-row .cm-message { flex: 1; min-width: 0; }
.channel-message-list .cm-add { align-self: flex-start; }
.channel-message-list template { display: none; }

/* --- Pages légales (CGU / confidentialité) : texte long, espacements classiques --- */
.legal-content h2 { margin-top: 1.6rem; color: var(--text); }
.legal-content h2:first-child { margin-top: 0; }
.legal-content p { margin-bottom: 0.9rem; line-height: 1.55; }
.legal-content ul { margin: 0 0 0.9rem; padding-left: 1.3rem; color: var(--text-muted); }
.legal-content li { margin-bottom: 0.35rem; line-height: 1.5; }

/* --- Page Statuts --- */
.status-row { display: flex; align-items: center; gap: 0.9rem; }
.status-row + .status-row { margin-top: 0.7rem; }
.status-dot { width: 11px; height: 11px; border-radius: 50%; background: var(--text-dim); flex-shrink: 0; }
.status-dot.is-online { background: var(--success); box-shadow: 0 0 8px rgba(50, 213, 131, 0.6); }
.status-dot.is-offline { background: var(--danger); box-shadow: 0 0 8px rgba(255, 92, 124, 0.6); }
.status-title { font-weight: 600; }
.status-detail { font-size: 0.83rem; color: var(--text-muted); }
.status-label { margin-left: auto; font-weight: 700; font-size: 0.85rem; }

/* --- Hero Premium --- */
.premium-hero {
  border-radius: 20px; padding: 2.5rem 2rem; margin-bottom: 2rem; text-align: center;
  background:
    radial-gradient(circle at 30% 0%, rgba(0, 217, 255, 0.18), transparent 55%),
    radial-gradient(circle at 80% 100%, rgba(118, 87, 255, 0.16), transparent 55%),
    var(--bg-secondary);
  border: 1px solid var(--border);
}
.premium-hero h1 { font-size: 2.1rem; margin-bottom: 0.6rem; }
.premium-hero p { max-width: 520px; margin: 0 auto; font-size: 0.98rem; }

.plan-card {
  position: relative; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.4rem; display: flex; flex-direction: column; gap: 0.5rem;
}
.plan-card.is-recommended {
  border: 1px solid transparent;
  background:
    linear-gradient(var(--bg-card), var(--bg-card)) padding-box,
    var(--gradient-premium) border-box;
  box-shadow: 0 0 30px rgba(118, 87, 255, 0.18);
}
.plan-card .plan-badge {
  position: absolute; top: -11px; left: 50%; transform: translateX(-50%);
  background: var(--gradient-premium); color: white; font-size: 0.68rem; font-weight: 700;
  padding: 0.25rem 0.7rem; border-radius: 999px; text-transform: uppercase; letter-spacing: 0.04em;
}

/* Formules sur une seule ligne + sélecteur de fréquence de paiement (/premium) */
.plan-grid-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.2rem; }
@media (max-width: 880px) {
  .plan-grid-row { grid-template-columns: 1fr; }
}
.frequency-selector {
  display: inline-flex; gap: 0.25rem; padding: 0.25rem; margin-bottom: 1.2rem;
  background: var(--bg-card); border: 1px solid var(--border); border-radius: 999px;
}
.frequency-option {
  border: none; background: transparent; color: var(--text-dim); font-size: 0.85rem; font-weight: 600;
  padding: 0.45rem 1rem; border-radius: 999px; cursor: pointer; transition: background 0.15s, color 0.15s;
}
.frequency-option:hover { color: var(--text); }
.frequency-option.is-active { background: var(--gradient-cta); color: #04121f; }
.plan-price-option, .plan-price-empty { display: none; }
.plan-price-option.is-active, .plan-price-empty.is-active { display: flex; }
.plan-price-option {
  flex-direction: column; align-items: center; text-align: center; gap: 0.3rem;
  padding-top: 0.75rem; margin-top: 0.75rem; border-top: 1px solid var(--border);
}
.plan-price-empty {
  align-items: center; justify-content: center; text-align: center; color: var(--text-dim);
  font-size: 0.85rem; padding-top: 0.75rem; margin-top: 0.75rem; border-top: 1px solid var(--border);
}
.plan-price-main { font-size: 1.6rem; font-weight: 800; }
.plan-price-main.plan-price-promo { color: var(--danger); }
.plan-price-old { font-size: 0.85rem; color: var(--text-dim); text-decoration: line-through; }
.plan-price-permonth { font-size: 0.8rem; color: var(--text-dim); }
.plan-price-option form { width: 100%; }
.plan-price-option .btn { width: 100%; }

/* Tableau comparatif des formules (/premium) — façon DraftBot : une ligne par
   plafond/fonctionnalité, une colonne par formule. */
.compare-table-wrap { padding: 0; overflow-x: auto; }
.compare-table { min-width: 640px; }
.compare-table th, .compare-table td { text-align: center; white-space: nowrap; }
.compare-table th:first-child, .compare-table td:first-child { text-align: left; white-space: normal; }
.compare-table th.is-recommended {
  background: var(--gradient-cta); color: #04121f; font-weight: 700;
}
.compare-table td.is-recommended { background: rgba(0, 217, 255, 0.06); }
.compare-section-row td {
  background: rgba(255, 255, 255, 0.02); font-size: 0.72rem; text-transform: uppercase;
  letter-spacing: 0.06em; color: var(--text-dim); font-weight: 700; padding-top: 1rem;
}
.compare-icon-cell svg.compare-icon-yes { color: var(--success); }
.compare-icon-cell svg.compare-icon-no { color: var(--danger); }

/* ==================================================
   Toasts
   ================================================== */
.toast-stack {
  position: fixed; top: 1.2rem; right: 1.2rem; z-index: 100;
  display: flex; flex-direction: column; gap: 0.6rem; max-width: 340px;
}
.toast {
  display: flex; align-items: flex-start; gap: 0.6rem;
  background: var(--bg-secondary); border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 0.75rem 0.9rem; box-shadow: 0 12px 32px rgba(0,0,0,0.4);
  font-size: 0.85rem; color: var(--text);
  animation: toast-in 0.25s var(--ease);
}
.toast.is-leaving { animation: toast-out 0.2s var(--ease) forwards; }
@keyframes toast-in { from { opacity: 0; transform: translateX(16px); } to { opacity: 1; transform: none; } }
@keyframes toast-out { to { opacity: 0; transform: translateX(16px); } }
.toast svg { flex-shrink: 0; margin-top: 0.1rem; }
.toast.toast-success svg { color: var(--success); }
.toast.toast-error svg { color: var(--danger); }
.toast.toast-warning svg { color: var(--warning); }

/* ==================================================
   Page publique /informations (aucune session requise)
   ================================================== */
.public-shell {
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(0, 140, 255, 0.14), transparent 45%),
    radial-gradient(circle at 85% 15%, rgba(118, 87, 255, 0.12), transparent 40%),
    var(--bg);
}
.public-header {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1180px; margin: 0 auto; padding: 1.5rem 2rem;
}
.public-brand { display: flex; align-items: center; gap: 0.6rem; text-decoration: none; color: var(--text); font-family: var(--font-heading); font-weight: 700; font-size: 1.15rem; }
.public-brand-logo { width: 34px; height: 34px; border-radius: 9px; }
.public-nav { display: flex; align-items: center; gap: 1rem; }

.public-hero { max-width: 780px; margin: 2.5rem auto 3rem; padding: 0 2rem; text-align: center; }
.public-hero h1 { font-family: var(--font-heading); font-size: 2.4rem; line-height: 1.15; margin: 0 0 0.9rem; }
.public-hero p { color: var(--text-muted); font-size: 1.05rem; line-height: 1.6; margin: 0; }

.public-stats {
  max-width: 780px; margin: 0 auto 3.5rem; padding: 0 2rem;
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 1.1rem;
}
.public-stat-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.5rem; text-align: center;
}
.public-stat-value { display: block; font-family: var(--font-heading); font-size: 2.1rem; font-weight: 700; background: var(--gradient-premium); -webkit-background-clip: text; background-clip: text; color: transparent; }
.public-stat-label { display: block; margin-top: 0.35rem; color: var(--text-dim); font-size: 0.85rem; }

.public-section { max-width: 1180px; margin: 0 auto 3.5rem; padding: 0 2rem; }

.public-marquee { overflow: hidden; mask-image: linear-gradient(90deg, transparent, #000 6%, #000 94%, transparent); }
.public-marquee-track { display: flex; gap: 1rem; width: max-content; animation: public-marquee-scroll 32s linear infinite; }
.public-marquee:hover .public-marquee-track { animation-play-state: paused; }
@keyframes public-marquee-scroll { from { transform: translateX(0); } to { transform: translateX(-50%); } }
/* Pas assez de serveurs pour remplir la largeur : liste statique et centrée,
   pas de défilement ni de duplication (voir MARQUEE_MIN_GUILDS dans la vue). */
.public-marquee.is-static { overflow: visible; mask-image: none; }
.public-marquee.is-static .public-marquee-track { width: 100%; flex-wrap: wrap; justify-content: center; animation: none; }
.public-guild-card {
  flex: 0 0 auto; width: 220px; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.1rem; text-align: center;
}
.public-guild-icon { width: 52px; height: 52px; border-radius: 14px; margin: 0 auto 0.7rem; }
.public-guild-icon-fallback { display: flex; align-items: center; justify-content: center; background: var(--bg-surface); color: var(--text-dim); }
.public-guild-name { font-weight: 600; margin-bottom: 0.8rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }

.public-staff-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.1rem; }
.public-staff-card { background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius); padding: 1.4rem; text-align: center; }
.public-staff-avatar { width: 64px; height: 64px; border-radius: 50%; margin: 0 auto 0.8rem; }
.public-staff-avatar-fallback { display: flex; align-items: center; justify-content: center; background: var(--bg-surface); color: var(--text-dim); }
.public-staff-name { font-weight: 700; }
.public-staff-role { color: var(--cyan); font-size: 0.82rem; margin-top: 0.2rem; }
.public-staff-bio { color: var(--text-muted); font-size: 0.86rem; line-height: 1.5; margin: 0.7rem 0 0; }

.public-news-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 1.1rem; }
.public-news-card {
  position: relative; background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  overflow: hidden; text-align: left;
}
.public-news-image { width: 100%; height: 150px; object-fit: cover; display: block; }
.public-news-body { padding: 1.2rem; }
.public-news-header { display: flex; align-items: center; gap: 0.7rem; margin-bottom: 0.6rem; }
.public-news-logo { width: 38px; height: 38px; border-radius: 10px; object-fit: cover; flex-shrink: 0; }
.public-news-title { font-weight: 700; }
.public-news-desc { color: var(--text-muted); font-size: 0.88rem; line-height: 1.55; margin: 0; }
.public-news-badge {
  position: absolute; top: 0.8rem; right: 0.8rem; z-index: 1;
  padding: 0.25rem 0.65rem; border-radius: 999px; font-size: 0.68rem; font-weight: 700;
  text-transform: uppercase; letter-spacing: 0.03em;
}
.public-news-badge-new { background: rgba(0, 217, 255, 0.9); color: #04222b; }
.public-news-badge-promo { background: var(--gradient-premium); color: white; box-shadow: 0 0 14px rgba(118, 87, 255, 0.45); }

.public-footer { max-width: 1180px; margin: 0 auto; padding: 2rem 2rem 3rem; text-align: center; color: var(--text-dim); font-size: 0.82rem; }
.public-footer-legal { display: flex; justify-content: flex-start; gap: 1.2rem; margin-top: 0.6rem; }
.public-footer-legal a { color: var(--text-dim); text-decoration: none; }
.public-footer-legal a:hover { color: var(--text-muted); text-decoration: underline; }

@media (max-width: 640px) {
  .public-header { flex-direction: column; gap: 1rem; padding: 1.25rem 1.25rem 0; }
  .public-hero h1 { font-size: 1.8rem; }
}
.toast.toast-info svg { color: var(--cyan); }

/* ==================================================
   Modal générique (pages "hub" : détail d'une sous-fonctionnalité)
   ================================================== */
.hub-modal-overlay {
  display: none;
  position: fixed; inset: 0; z-index: 100;
  background: rgba(2, 5, 15, 0.65); backdrop-filter: blur(2px);
  align-items: center; justify-content: center; padding: 1.5rem;
}
.hub-modal-overlay.is-open { display: flex; }
.hub-modal {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  box-shadow: 0 20px 60px rgba(0,0,0,0.4);
  width: 100%; max-width: 640px; max-height: min(85vh, 800px);
  display: flex; flex-direction: column;
}
.hub-modal-header {
  display: flex; align-items: center; justify-content: space-between; gap: 1rem;
  padding: 1.1rem 1.4rem; border-bottom: 1px solid var(--border); flex-shrink: 0;
}
.hub-modal-header h3 { margin: 0; font-family: var(--font-heading); font-size: 1.05rem; display: flex; align-items: center; gap: 0.5rem; }
.hub-modal-close {
  background: none; border: none; color: var(--text-dim); cursor: pointer;
  padding: 0.3rem; border-radius: 8px; display: flex;
}
.hub-modal-close:hover { background: var(--bg-surface); color: var(--text); }
.hub-modal-body { padding: 1.4rem; overflow-y: auto; }
.hub-modal-body .section:first-child { margin-top: 0; }
.hub-modal-body .section:last-child { margin-bottom: 0; }

/* ==================================================
   Grille de cartes "hub" (regroupement de plusieurs fonctionnalités liées)
   ================================================== */
.hub-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 1rem; }
.hub-card {
  background: var(--bg-card); border: 1px solid var(--border); border-radius: var(--radius);
  padding: 1.1rem; display: flex; flex-direction: column; gap: 0.8rem; transition: opacity 0.15s var(--ease);
}
.hub-card.is-off { opacity: 0.6; }
.hub-card-top { display: flex; align-items: flex-start; justify-content: space-between; gap: 0.75rem; }
.hub-card-title { display: flex; align-items: center; gap: 0.6rem; font-weight: 600; }
.hub-card-desc { color: var(--text-muted); font-size: 0.85rem; line-height: 1.5; margin: 0; }
.hub-card-footer { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; margin-top: auto; }
.hub-card-gear {
  background: var(--bg-surface); border: 1px solid var(--border); color: var(--text-muted);
  border-radius: 8px; padding: 0.45rem; cursor: pointer; display: flex;
}
.hub-card-gear:hover { color: var(--text); border-color: var(--text-dim); }

/* Champs répétables (boutons de lien, questions de formulaire pré-ticket) —
   remplace l'ancienne syntaxe texte "Label | URL" par de vraies lignes de
   champs, ajoutées/retirées dynamiquement (voir initRepeaters() dans main.js). */
.repeater-rows { display: flex; flex-direction: column; gap: 0.5rem; margin-bottom: 0.6rem; }
.repeater-row {
  display: flex; align-items: center; gap: 0.5rem; padding: 0.5rem;
  background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-sm);
}
.repeater-row input, .repeater-row select { width: auto; flex: 1; min-width: 0; }
.repeater-row .checkbox-field { flex: 0 0 auto; white-space: nowrap; }
.repeater-remove {
  flex: 0 0 auto; background: none; border: 1px solid var(--border); color: var(--text-dim);
  border-radius: 6px; padding: 0.4rem; cursor: pointer; display: flex;
}
.repeater-remove:hover { color: var(--danger); border-color: var(--danger); }
.repeater-empty-hint { font-size: 0.82rem; color: var(--text-dim); padding: 0.4rem 0; }
