/*
  Convention Gateway — feuille de style du site
  Charte : site convention-solutions.com (dépôt Convention Website, thème sombre, palette 2026 de l'interface)
  et kit de logos Convention (\\hercule.syselio.local\Syselio\Graphisme\Convention, août 2026).
  Les logos gardent leurs teintes d'origine ; la palette ci-dessous habille l'interface.
*/

:root {
    --background: #0f0f0f;
    --foreground: #f7f5f3;
    --card: #171717;
    --secondary: #1f1f1f;
    --muted: #1f1f1f;
    --muted-foreground: #ada89f;
    --border: #262626;
    --primary: #1fd5f9;
    --primary-foreground: #0f0f0f;
    --accent: #fa8638;
    --destructive: #ef4444;

    --bubble-cyan: #1fd5f9;
    --bubble-orange: #fa8638;
    --bubble-pink: #f36896;
    --bubble-lime: #b7e236;
    --bubble-violet: #9b63e9;
    --bubble-blue: #428bf0;
    --bubble-yellow: #fac938;
    --bubble-magenta: #e64dcc;

    --tone-success: #b7e236;
    --tone-error: #f36896;
    --tone-pending: #fac938;
    --tone-info: #1fd5f9;
    --tone-neutral: #ada89f;

    --radius: 1rem;
    --gradient-hero: radial-gradient(ellipse 80% 50% at 50% 0%, rgba(31, 213, 249, .18), transparent 70%),
                     radial-gradient(ellipse 60% 40% at 80% 30%, rgba(250, 134, 56, .12), transparent 70%),
                     radial-gradient(ellipse 60% 40% at 20% 40%, rgba(155, 99, 233, .12), transparent 70%);
    --gradient-text: linear-gradient(135deg, #f7f5f3, #6ae3fb);
    --gradient-orb: conic-gradient(from 180deg, #1fd5f9, #9b63e9, #f36896, #fa8638, #b7e236, #1fd5f9);
    --shadow-glow: 0 0 80px rgba(31, 213, 249, .3);
    --shadow-card: 0 1px 0 rgba(247, 245, 243, .05) inset, 0 20px 60px -20px rgba(0, 0, 0, .5);
    --ease: cubic-bezier(.22, 1, .36, 1);

    --font-sans: "Yanone Kaffeesatz", ui-sans-serif, system-ui, sans-serif;
    --font-serif: "Instrument Serif", ui-serif, Georgia, serif;
    --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", monospace;
    --header-height: 88px;
}

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

/* L'attribut hidden l'emporte sur les display des composants (bouton d'effacement, message « aucun résultat ») */
[hidden] { display: none !important; }

html { scroll-behavior: smooth; scroll-padding-top: 96px; -webkit-text-size-adjust: 100%; }

body {
    margin: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    background-color: var(--background);
    background-image: radial-gradient(circle at 20% 0, rgba(31, 213, 249, .08), transparent 50%),
                      radial-gradient(circle at 80% 100%, rgba(155, 99, 233, .08), transparent 50%);
    background-attachment: fixed;
    color: var(--foreground);
    font-family: var(--font-sans);
    font-size: 17px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

main { flex: 1 0 auto; }

img, svg { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button, input, select { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
ul, ol { margin: 0; padding: 0; list-style: none; }

::selection { background: rgba(31, 213, 249, .35); }

:focus-visible { outline: 2px solid var(--primary); outline-offset: 3px; border-radius: 6px; }

.icon { width: 1em; height: 1em; flex-shrink: 0; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

.container { width: 100%; max-width: 72rem; margin: 0 auto; padding-left: 1.5rem; padding-right: 1.5rem; }
.container-wide { max-width: 88rem; }

.serif { font-family: var(--font-serif); font-style: italic; font-weight: 400; }
.gradient-text { background: var(--gradient-text); -webkit-background-clip: text; background-clip: text; color: transparent; }
.muted { color: var(--muted-foreground); }
.tabular { font-variant-numeric: tabular-nums; }

.glass { background: rgba(23, 23, 23, .92); -webkit-backdrop-filter: blur(20px) saturate(140%); backdrop-filter: blur(20px) saturate(140%); border: 1px solid rgba(247, 245, 243, .08); }

/* ---------- En-tête ---------- */

.gw-header { position: fixed; top: 0; left: 0; right: 0; z-index: 50; padding: 1.25rem 1.5rem 0; background: linear-gradient(to bottom, var(--background) 60%, transparent); }
.gw-nav { max-width: 72rem; margin: 0 auto; border-radius: 9999px; padding: .25rem .5rem .25rem 1.25rem; display: flex; align-items: center; justify-content: space-between; gap: .75rem; min-height: 56px; }
.app .gw-nav { max-width: 88rem; }

.gw-brand { display: flex; align-items: center; gap: .6rem; flex-shrink: 0; }
.gw-brand img { height: 38px; width: auto; }
.gw-brand-product { font-weight: 300; font-size: 1.55rem; line-height: 1; letter-spacing: -.01em; color: var(--primary); padding-left: .6rem; border-left: 1px solid rgba(247, 245, 243, .15); }

.gw-links { display: flex; align-items: center; gap: 2rem; font-size: .95rem; color: var(--muted-foreground); }
.gw-links a { transition: color .2s; white-space: nowrap; }
.gw-links a:hover, .gw-links a[aria-current="page"] { color: var(--foreground); }

.gw-actions { display: flex; align-items: center; gap: .5rem; }

.gw-user { display: flex; align-items: center; gap: .6rem; padding-right: .25rem; }
.gw-avatar { width: 34px; height: 34px; border-radius: 9999px; display: grid; place-items: center; font-weight: 600; font-size: .85rem; color: var(--primary-foreground); background: var(--gradient-orb); }
.gw-user-name { font-size: .95rem; line-height: 1.1; max-width: 12rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.gw-user-name small { display: block; color: var(--muted-foreground); font-size: .75rem; letter-spacing: .08em; text-transform: uppercase; }

.gw-menu-toggle { display: none; background: none; border: 0; width: 40px; height: 40px; border-radius: 9999px; align-items: center; justify-content: center; cursor: pointer; font-size: 1.3rem; }
.gw-menu-toggle:hover { background: var(--secondary); }

.gw-mobile-menu { display: none; }

@media (max-width: 860px) {
    .gw-links, .gw-actions .gw-user-name, .gw-actions .hide-mobile { display: none; }
    .gw-menu-toggle { display: inline-flex; }
    .gw-mobile-menu[data-open="true"] { display: block; position: fixed; top: 84px; left: 1rem; right: 1rem; z-index: 49; border-radius: 1.5rem; padding: 1rem; }
    .gw-mobile-menu a, .gw-mobile-menu button { display: flex; align-items: center; gap: .6rem; width: 100%; padding: .75rem 1rem; border-radius: .75rem; font-size: 1.1rem; background: none; border: 0; text-align: left; cursor: pointer; }
    .gw-mobile-menu a:hover, .gw-mobile-menu button:hover { background: var(--secondary); }
    .gw-brand img { height: 32px; }
    .gw-brand-product { font-size: 1.3rem; }
}

/* ---------- Boutons ---------- */

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border-radius: 9999px; padding: .85rem 1.5rem; font-size: 1.05rem; font-weight: 500; line-height: 1.1; border: 1px solid transparent; cursor: pointer; transition: background-color .25s, color .25s, opacity .25s, border-color .25s, transform .25s var(--ease); white-space: nowrap; }
.btn .icon { transition: transform .3s var(--ease); }
.btn:hover .icon-arrow { transform: translateX(3px); }
.btn-primary { background: var(--primary); color: var(--primary-foreground); box-shadow: var(--shadow-glow); }
.btn-primary:hover { opacity: .9; }
.btn-light { background: var(--foreground); color: var(--background); padding: .55rem 1.1rem; font-size: .95rem; }
.btn-light:hover { background: var(--primary); color: var(--primary-foreground); }
.btn-glass { background: rgba(255, 255, 255, .05); border-color: rgba(255, 255, 255, .3); color: #fff; -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); }
.btn-glass:hover { background: rgba(255, 255, 255, .1); }
.btn-outline { background: transparent; border-color: var(--border); color: var(--foreground); }
.btn-outline:hover { background: var(--card); border-color: #3a3a3a; }
.btn-ghost { background: transparent; color: var(--muted-foreground); padding: .55rem .9rem; font-size: .95rem; }
.btn-ghost:hover { color: var(--foreground); background: var(--secondary); }
.btn-sm { padding: .5rem 1rem; font-size: .95rem; }

/* ---------- Titres de section ---------- */

.eyebrow { font-size: .8rem; text-transform: uppercase; letter-spacing: .3em; color: var(--primary); }
.eyebrow-accent { color: var(--accent); }
.section { padding: 7rem 0; position: relative; }
.section-border { border-top: 1px solid var(--border); }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem; margin-bottom: 3.5rem; }
.section-title { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 300; line-height: .95; letter-spacing: -.025em; margin-top: 1rem; text-wrap: balance; }
.section-lead { max-width: 26rem; color: var(--muted-foreground); font-size: 1.05rem; }

/* ---------- Héros ---------- */

.hero { position: relative; min-height: 100vh; display: flex; align-items: center; overflow: hidden; isolation: isolate; }
.hero-media { position: absolute; inset: 0; z-index: -2; }
.hero-media img { width: 100%; height: 100%; object-fit: cover; }
.hero-media::after { content: ""; position: absolute; inset: 0; background: rgba(15, 15, 15, .55); }
.hero::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--gradient-hero), linear-gradient(to bottom, rgba(15, 15, 15, .2) 0%, transparent 30%, transparent 70%, var(--background) 100%); }
.hero-content { position: relative; text-align: center; padding-top: 8rem; padding-bottom: 5rem; max-width: 64rem; }
.hero-pill { display: inline-flex; align-items: center; gap: .5rem; border-radius: 9999px; border: 1px solid rgba(255, 255, 255, .2); background: rgba(255, 255, 255, .05); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); padding: .4rem 1rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .1em; color: rgba(255, 255, 255, .75); margin-bottom: 2rem; }
.hero-pill .dot { width: 6px; height: 6px; border-radius: 9999px; background: var(--primary); box-shadow: 0 0 12px var(--primary); animation: pulse 2s ease-in-out infinite; }
.hero-title { font-size: clamp(2.9rem, 8vw, 7rem); line-height: .95; font-weight: 300; letter-spacing: -.025em; color: #fff; text-wrap: balance; text-shadow: 0 25px 25px rgba(0, 0, 0, .15); }
.hero-lead { margin: 2rem auto 0; max-width: 40rem; color: rgba(255, 255, 255, .8); font-size: 1.2rem; }
.hero-cta { margin-top: 2.5rem; display: flex; flex-wrap: wrap; justify-content: center; gap: .75rem; }
.hero-note { margin-top: 1.5rem; font-size: .9rem; color: rgba(255, 255, 255, .55); display: inline-flex; align-items: center; gap: .4rem; }

.orb { position: absolute; border-radius: 9999px; background: var(--gradient-orb); filter: blur(64px); opacity: .35; pointer-events: none; animation: float-slow 8s ease-in-out infinite; }
.floating-dot { position: absolute; border-radius: 9999px; pointer-events: none; animation: float-slow 8s ease-in-out infinite; }

@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: .4; } }
@keyframes float-slow { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-20px); } }
@keyframes marquee { from { transform: translateX(0); } to { transform: translateX(-50%); } }
@keyframes fade-up { from { opacity: 0; transform: translateY(24px); } to { opacity: 1; transform: none; } }
@keyframes spin { to { transform: rotate(360deg); } }

.animate-fade-up { animation: fade-up .8s var(--ease) both; }
.delay-1 { animation-delay: .1s; }
.delay-2 { animation-delay: .2s; }
.delay-3 { animation-delay: .3s; }

.reveal { opacity: 0; transform: translateY(24px); transition: opacity .8s var(--ease), transform .8s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
    .reveal { opacity: 1; transform: none; transition: none; }
    .orb, .floating-dot, .marquee-track, .animate-fade-up, .hero-pill .dot { animation: none; }
    html { scroll-behavior: auto; }
}

/* ---------- Bandeau défilant ---------- */

.marquee { border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); overflow: hidden; padding: 1.4rem 0; -webkit-mask-image: linear-gradient(to right, transparent, #000 10%, #000 90%, transparent); mask-image: linear-gradient(to right, transparent, #000 10%, #000 90%, transparent); }
.marquee-track { display: flex; width: max-content; gap: 3rem; animation: marquee 40s linear infinite; }
.marquee-item { display: inline-flex; align-items: center; gap: 3rem; font-size: 1.6rem; font-weight: 300; color: var(--muted-foreground); white-space: nowrap; }
.marquee-item::after { content: ""; width: 8px; height: 8px; border-radius: 9999px; background: var(--gradient-orb); }

/* ---------- Grille de fonctionnalités (cartes des modules du site) ---------- */

.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border-radius: 2rem; overflow: hidden; border: 1px solid var(--border); }
.feature-card { position: relative; background: var(--card); padding: 2rem; min-height: 260px; display: flex; flex-direction: column; transition: background-color .5s; }
.feature-card:hover { background: var(--secondary); }
.feature-card-top { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 2.5rem; }
.feature-tag { font-size: .7rem; text-transform: uppercase; letter-spacing: .2em; color: var(--muted-foreground); }
.feature-card h3 { font-size: 1.6rem; font-weight: 600; margin-bottom: .6rem; }
.feature-card p { color: var(--muted-foreground); font-size: 1.02rem; }

.bubble { width: 48px; height: 48px; border-radius: 9999px; display: grid; place-items: center; color: var(--background); font-size: 1.3rem; background: var(--bubble, var(--primary)); box-shadow: 0 0 24px color-mix(in srgb, var(--bubble, var(--primary)) 50%, transparent); flex-shrink: 0; }
.bubble-sm { width: 36px; height: 36px; font-size: 1.05rem; }

@media (max-width: 960px) { .feature-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 620px) { .feature-grid { grid-template-columns: 1fr; } .feature-card { min-height: 0; } }

/* ---------- Chiffres ---------- */

.stats { display: grid; grid-template-columns: repeat(4, 1fr); gap: 2rem; }
.stat-value { font-size: clamp(2.8rem, 5vw, 4.5rem); font-weight: 200; line-height: 1; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.stat-label { margin-top: .6rem; font-size: .8rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted-foreground); }
@media (max-width: 760px) { .stats { grid-template-columns: repeat(2, 1fr); } }

/* ---------- Déroulé (workflow) ---------- */

.steps { display: grid; grid-template-columns: repeat(2, 1fr); column-gap: 4rem; }
.step { display: flex; gap: 1.5rem; padding: 2rem 0; border-top: 1px solid var(--border); }
.step-number { font-family: var(--font-serif); font-style: italic; font-size: 2.6rem; line-height: 1; color: var(--muted-foreground); min-width: 3.2rem; }
.step h3 { font-size: 1.6rem; font-weight: 600; margin-bottom: .35rem; }
.step p { color: var(--muted-foreground); }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

/* ---------- Aperçu de l'espace client ---------- */

.showcase { display: grid; grid-template-columns: 1fr 1.25fr; gap: 4rem; align-items: center; }
.showcase-list { margin-top: 2rem; display: grid; gap: 1.25rem; }
.showcase-list li { display: flex; gap: 1rem; align-items: flex-start; }
.showcase-list h3 { font-size: 1.35rem; font-weight: 600; }
.showcase-list p { color: var(--muted-foreground); }
.mockup { position: relative; border-radius: 1.75rem; border: 1px solid var(--border); background: var(--card); box-shadow: var(--shadow-card); padding: 1.25rem; overflow: hidden; }
.mockup::before { content: ""; position: absolute; inset: 0; background: var(--gradient-hero); opacity: .7; pointer-events: none; }
.mockup > * { position: relative; }
.mockup-bar { display: flex; gap: 6px; margin-bottom: 1rem; }
.mockup-bar span { width: 10px; height: 10px; border-radius: 9999px; background: #333; }
.mockup-kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: .75rem; margin-bottom: .75rem; }
.mockup-kpi { background: rgba(15, 15, 15, .7); border: 1px solid var(--border); border-radius: 1rem; padding: .8rem 1rem; }
.mockup-kpi b { display: block; font-size: 1.8rem; font-weight: 300; line-height: 1.1; }
.mockup-kpi span { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted-foreground); }
.mockup-chart { display: flex; align-items: flex-end; gap: 5px; height: 90px; padding: .75rem 1rem; background: rgba(15, 15, 15, .7); border: 1px solid var(--border); border-radius: 1rem; margin-bottom: .75rem; }
.mockup-chart i { flex: 1; border-radius: 4px 4px 1px 1px; background: linear-gradient(to top, var(--tone-success), rgba(183, 226, 54, .5)); }
.mockup-chart i.err { background: linear-gradient(to top, var(--tone-error), rgba(243, 104, 150, .5)); }
.mockup-search { display: flex; align-items: center; gap: .6rem; padding: .7rem 1rem; border-radius: 9999px; background: rgba(15, 15, 15, .85); border: 1px solid rgba(31, 213, 249, .45); box-shadow: 0 0 30px rgba(31, 213, 249, .15); margin-bottom: .6rem; color: var(--muted-foreground); }
.mockup-search b { color: var(--foreground); font-weight: 400; }
.mockup-search .caret { width: 1px; height: 1.1em; background: var(--primary); animation: pulse 1s steps(1) infinite; }
.mockup-row { display: grid; grid-template-columns: 1.4fr 1fr auto; gap: .75rem; align-items: center; padding: .55rem .9rem; border-radius: .75rem; font-size: .95rem; }
.mockup-row:nth-child(odd) { background: rgba(255, 255, 255, .025); }
.mockup-row mark { background: rgba(31, 213, 249, .22); color: var(--foreground); border-radius: 3px; padding: 0 1px; }
@media (max-width: 960px) { .showcase { grid-template-columns: 1fr; } }

/* ---------- Compatibilité modules Convention ---------- */

.modules-strip { display: flex; flex-wrap: wrap; gap: 1rem 2.5rem; align-items: center; }
.modules-strip img { height: 34px; width: auto; }
.suite-banner { margin-top: 3rem; opacity: .9; }
.suite-banner img { width: 100%; max-width: 56rem; height: auto; }

/* ---------- Appel à l'action ---------- */

.cta { position: relative; max-width: 64rem; margin: 0 auto; border-radius: 2.5rem; border: 1px solid var(--border); background: var(--gradient-hero), var(--card); padding: 5rem 2rem; text-align: center; overflow: hidden; isolation: isolate; }
.cta .orb { z-index: -1; }
.cta h2 { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 300; line-height: 1; letter-spacing: -.025em; }
.cta p { max-width: 34rem; margin: 1.5rem auto 0; color: var(--muted-foreground); font-size: 1.1rem; }
.cta .hero-cta { margin-top: 2.25rem; }

/* ---------- Pied de page ---------- */

.gw-footer { border-top: 1px solid var(--border); padding: 3rem 0; margin-top: 4rem; }
.gw-footer-inner { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem; }
.gw-footer-brand { display: flex; align-items: center; gap: .9rem; color: var(--muted-foreground); font-size: .95rem; }
.gw-footer-brand img { height: 30px; width: auto; }
.gw-footer-links { display: flex; flex-wrap: wrap; gap: 1.5rem; font-size: .95rem; color: var(--muted-foreground); }
.gw-footer-links a:hover { color: var(--foreground); }
.app .gw-footer { margin-top: 3rem; }

/* ====================================================================== */
/* Espace des événements                                                   */
/* ====================================================================== */

.app-main { padding-top: calc(var(--header-height) + 2.25rem); padding-bottom: 2rem; }

.page-head { display: flex; align-items: flex-end; justify-content: space-between; flex-wrap: wrap; gap: 1.5rem; margin-bottom: 2rem; }
.page-title { font-size: clamp(2.3rem, 5vw, 3.8rem); font-weight: 300; line-height: 1; letter-spacing: -.02em; margin-top: .6rem; text-wrap: balance; }
.page-subtitle { margin-top: .75rem; color: var(--muted-foreground); font-size: 1.1rem; display: flex; flex-wrap: wrap; align-items: center; gap: .4rem 1.25rem; }
.page-subtitle span { display: inline-flex; align-items: center; gap: .4rem; }

.breadcrumb { display: flex; align-items: center; flex-wrap: wrap; gap: .35rem; font-size: .95rem; color: var(--muted-foreground); }
.breadcrumb a:hover { color: var(--foreground); }
.breadcrumb .icon { font-size: .85rem; opacity: .6; }

.tabs { display: inline-flex; gap: .25rem; padding: .3rem; border-radius: 9999px; border: 1px solid var(--border); background: var(--card); }
.tab { display: inline-flex; align-items: center; gap: .5rem; padding: .55rem 1.1rem; border-radius: 9999px; color: var(--muted-foreground); font-size: 1rem; transition: background-color .2s, color .2s; }
.tab:hover { color: var(--foreground); }
.tab[aria-current="page"] { background: var(--foreground); color: var(--background); }
.tab .count { font-size: .8rem; padding: 0 .45rem; border-radius: 9999px; background: rgba(243, 104, 150, .2); color: var(--tone-error); }
.tab[aria-current="page"] .count { background: rgba(15, 15, 15, .12); color: var(--background); }

.alert { display: flex; gap: .8rem; align-items: flex-start; border-radius: 1rem; padding: 1rem 1.25rem; border: 1px solid var(--border); background: var(--card); margin-bottom: 1.5rem; }
.alert .icon { font-size: 1.25rem; margin-top: .1rem; }
.alert-warning { border-color: rgba(250, 201, 56, .35); background: rgba(250, 201, 56, .06); }
.alert-warning .icon { color: var(--tone-pending); }
.alert-error { border-color: rgba(243, 104, 150, .35); background: rgba(243, 104, 150, .06); }
.alert-error .icon { color: var(--tone-error); }
.alert-info .icon { color: var(--primary); }

/* Indicateurs */

.kpi-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 1px; background: var(--border); border: 1px solid var(--border); border-radius: 1.75rem; overflow: hidden; margin-bottom: 1.5rem; }
.kpi { background: var(--card); padding: 1.5rem 1.6rem; display: flex; flex-direction: column; gap: .3rem; min-width: 0; transition: background-color .3s; }
a.kpi:hover { background: var(--secondary); }
.kpi-label { display: flex; align-items: center; gap: .5rem; font-size: .78rem; text-transform: uppercase; letter-spacing: .14em; color: var(--muted-foreground); }
.kpi-label .icon { font-size: 1rem; color: var(--kpi-color, var(--primary)); }
.kpi-value { font-size: clamp(2.4rem, 4vw, 3.4rem); font-weight: 200; line-height: 1.05; letter-spacing: -.02em; font-variant-numeric: tabular-nums; }
.kpi-detail { font-size: .95rem; color: var(--muted-foreground); }
.kpi-alert .kpi-value { color: var(--tone-error); }
.kpi-ok .kpi-value { color: var(--tone-success); }
@media (max-width: 1000px) { .kpi-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 480px) { .kpi-grid { grid-template-columns: 1fr; } }

/* Panneaux */

.dashboard-grid { display: grid; grid-template-columns: 1.6fr 1fr; gap: 1.5rem; margin-bottom: 1.5rem; }
@media (max-width: 1000px) { .dashboard-grid { grid-template-columns: 1fr; } }

.panel { background: var(--card); border: 1px solid var(--border); border-radius: 1.75rem; padding: 1.6rem; min-width: 0; }
.panel-head { display: flex; align-items: baseline; justify-content: space-between; gap: 1rem; flex-wrap: wrap; margin-bottom: 1.25rem; }
.panel-title { font-size: 1.5rem; font-weight: 500; }
.panel-subtitle { color: var(--muted-foreground); font-size: .95rem; }
.panel-link { display: inline-flex; align-items: center; gap: .3rem; color: var(--primary); font-size: .95rem; }
.panel-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.panel + .panel { margin-top: 1.5rem; }
.panel-flush { padding: 0; overflow: hidden; }
.panel-flush .panel-head { padding: 1.6rem 1.6rem 0; }

/* Graphique d'activité */

.chart { display: flex; align-items: flex-end; gap: 4px; height: 200px; padding-top: .5rem; }
.chart-bar { flex: 1; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; min-width: 0; position: relative; }
.chart-bar i { display: block; width: 100%; }
.chart-bar i:first-child { border-radius: 4px 4px 0 0; }
.chart-bar .seg-success { background: var(--tone-success); }
.chart-bar .seg-error { background: var(--tone-error); }
.chart-bar .seg-other { background: #4b4b4b; }
.chart-bar .seg-empty { background: #232323; height: 2px; border-radius: 2px; }
.chart-bar:hover i { filter: brightness(1.2); }
.chart-axis { display: flex; justify-content: space-between; margin-top: .6rem; font-size: .85rem; color: var(--muted-foreground); }
.legend { display: flex; flex-wrap: wrap; gap: .4rem 1.2rem; font-size: .9rem; color: var(--muted-foreground); }
.legend span { display: inline-flex; align-items: center; gap: .4rem; }
.legend i { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }

/* Répartition par statut */

.status-bar { display: flex; height: 12px; border-radius: 9999px; overflow: hidden; background: var(--secondary); margin: .5rem 0 1.25rem; }
.status-bar i { display: block; height: 100%; }
.status-list { display: grid; gap: .55rem; }
.status-list a { display: grid; grid-template-columns: auto 1fr auto auto; gap: .75rem; align-items: center; padding: .4rem .6rem; margin: 0 -.6rem; border-radius: .6rem; transition: background-color .2s; }
.status-list a:hover { background: var(--secondary); }
.status-list .dot { width: 10px; height: 10px; border-radius: 9999px; }
.status-list .value { font-variant-numeric: tabular-nums; }
.status-list .percent { color: var(--muted-foreground); font-size: .9rem; min-width: 3.5rem; text-align: right; font-variant-numeric: tabular-nums; }

.facts { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; margin-top: 1.5rem; padding-top: 1.25rem; border-top: 1px solid var(--border); }
.fact dt { font-size: .75rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted-foreground); }
.fact dd { margin: .2rem 0 0; font-size: 1.15rem; }

/* Statuts */

.status { --tone: var(--tone-neutral); display: inline-flex; align-items: center; gap: .4rem; padding: .2rem .7rem .2rem .55rem; border-radius: 9999px; font-size: .9rem; line-height: 1.4; white-space: nowrap; color: var(--tone); background: color-mix(in srgb, var(--tone) 12%, transparent); border: 1px solid color-mix(in srgb, var(--tone) 30%, transparent); }
.status::before { content: ""; width: 7px; height: 7px; border-radius: 9999px; background: var(--tone); }
.tone-success { --tone: var(--tone-success); }
.tone-error { --tone: var(--tone-error); }
.tone-pending { --tone: var(--tone-pending); }
.tone-info { --tone: var(--tone-info); }
.tone-neutral { --tone: var(--tone-neutral); }
.tone-dot { background: var(--tone) !important; }

.nature { display: inline-flex; align-items: center; gap: .35rem; font-size: .95rem; color: var(--muted-foreground); white-space: nowrap; }
.nature-cancel { color: var(--accent); }

/* Tableaux */

.table-wrap { overflow-x: auto; -webkit-overflow-scrolling: touch; }
.table { width: 100%; border-collapse: collapse; font-size: 1rem; }
.table th { text-align: left; font-weight: 400; font-size: .75rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted-foreground); padding: .9rem 1rem; border-bottom: 1px solid var(--border); white-space: nowrap; }
.table td { padding: .85rem 1rem; border-bottom: 1px solid rgba(38, 38, 38, .7); vertical-align: top; }
.table tbody tr { transition: background-color .15s; }
.table tbody tr:hover { background: rgba(255, 255, 255, .025); }
.table tbody tr:last-child td { border-bottom: 0; }
.table .num { text-align: right; font-variant-numeric: tabular-nums; }
.table .nowrap { white-space: nowrap; }
.table tr[data-href] { cursor: pointer; }
.table .primary-cell { font-size: 1.1rem; }
.table .primary-cell a:hover { color: var(--primary); }
.table .secondary { display: block; color: var(--muted-foreground); font-size: .9rem; }
.table .error-text { display: block; margin-top: .3rem; color: var(--tone-error); font-size: .9rem; max-width: 34rem; overflow: hidden; text-overflow: ellipsis; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.table-compact td { padding: .7rem 1rem; }

mark { background: rgba(31, 213, 249, .22); color: var(--foreground); border-radius: 3px; padding: 0 1px; }

.hotel-cell { display: flex; align-items: center; gap: .75rem; }
.hotel-cell .bubble { font-size: 1rem; }

/* Barre de filtres */

.filters { background: var(--card); border: 1px solid var(--border); border-radius: 1.75rem; padding: 1.25rem; margin-bottom: 1.25rem; }
.search { position: relative; }
.search > .icon { position: absolute; left: 1.25rem; top: 50%; transform: translateY(-50%); font-size: 1.3rem; color: var(--muted-foreground); pointer-events: none; }
.search input { width: 100%; height: 3.6rem; padding: 0 7.5rem 0 3.4rem; border-radius: 9999px; border: 1px solid var(--border); background: var(--background); font-size: 1.3rem; outline: none; transition: border-color .2s, box-shadow .2s; }
.search input::placeholder { color: #77736c; }
.search input:focus { border-color: rgba(31, 213, 249, .6); box-shadow: 0 0 0 4px rgba(31, 213, 249, .12), 0 0 40px rgba(31, 213, 249, .12); }
.search-hint { position: absolute; right: .6rem; top: 50%; transform: translateY(-50%); display: flex; align-items: center; gap: .4rem; }
.search-mode { font-size: .75rem; text-transform: uppercase; letter-spacing: .1em; color: var(--primary); background: rgba(31, 213, 249, .1); border: 1px solid rgba(31, 213, 249, .25); border-radius: 9999px; padding: .3rem .7rem; white-space: nowrap; }
.search-clear { display: grid; place-items: center; width: 34px; height: 34px; border-radius: 9999px; border: 0; background: var(--secondary); cursor: pointer; color: var(--muted-foreground); }
.search-clear:hover { color: var(--foreground); }
.search-help { margin: .6rem 0 0 1.4rem; font-size: .9rem; color: var(--muted-foreground); }

.filter-row { display: flex; flex-wrap: wrap; align-items: flex-end; gap: .75rem; margin-top: 1rem; }
.field { display: flex; flex-direction: column; gap: .3rem; min-width: 0; }
.field label, .field-label { font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted-foreground); padding-left: .9rem; }
.field select, .field input[type="date"] { height: 2.7rem; padding: 0 2.2rem 0 1rem; border-radius: 9999px; border: 1px solid var(--border); background-color: var(--background); font-size: 1rem; outline: none; min-width: 9.5rem; color-scheme: dark; }
.field select { appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23ada89f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .9rem center; }
.field input[type="date"] { padding-right: 1rem; min-width: 9rem; }
.field select:focus, .field input:focus { border-color: rgba(31, 213, 249, .6); }
.field select.is-set, .field input.is-set { border-color: rgba(31, 213, 249, .45); background-color: rgba(31, 213, 249, .06); }

.toggle { display: inline-flex; align-items: center; gap: .6rem; height: 2.7rem; padding: 0 1rem 0 .5rem; border-radius: 9999px; border: 1px solid var(--border); cursor: pointer; user-select: none; white-space: nowrap; }
.toggle input { appearance: none; -webkit-appearance: none; width: 2.2rem; height: 1.3rem; border-radius: 9999px; background: #333; position: relative; cursor: pointer; transition: background-color .2s; margin: 0; }
.toggle input::after { content: ""; position: absolute; top: 3px; left: 3px; width: calc(1.3rem - 6px); height: calc(1.3rem - 6px); border-radius: 9999px; background: var(--foreground); transition: transform .2s var(--ease); }
.toggle input:checked { background: var(--primary); }
.toggle input:checked::after { transform: translateX(.9rem); background: var(--background); }

.filter-actions { margin-left: auto; display: flex; gap: .5rem; align-items: center; }

.quick-status { display: flex; flex-wrap: wrap; gap: .5rem; margin-bottom: 1.25rem; }
.chip { display: inline-flex; align-items: center; gap: .45rem; padding: .4rem .9rem; border-radius: 9999px; border: 1px solid var(--border); background: var(--card); font-size: .95rem; color: var(--muted-foreground); transition: border-color .2s, color .2s, background-color .2s; }
.chip:hover { color: var(--foreground); border-color: #3a3a3a; }
.chip[aria-current="true"] { color: var(--background); background: var(--foreground); border-color: var(--foreground); }
.chip b { font-weight: 400; font-variant-numeric: tabular-nums; opacity: .75; }
.chip .dot { width: 8px; height: 8px; border-radius: 9999px; background: var(--tone); }

.results-head { display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap; padding: 1.1rem 1.6rem; border-bottom: 1px solid var(--border); }
.results-count { font-size: 1.1rem; }
.results-count b { font-weight: 500; font-variant-numeric: tabular-nums; }
.results { position: relative; transition: opacity .2s; }
.results.is-loading { opacity: .55; }
.results.is-loading::after { content: ""; position: absolute; top: 1.2rem; right: 1.6rem; width: 18px; height: 18px; border-radius: 9999px; border: 2px solid var(--border); border-top-color: var(--primary); animation: spin .7s linear infinite; }

.sort select { height: 2.3rem; min-width: 0; }

/* Formulaires (gestion des accès) */
.form-stack { display: grid; gap: 1rem; }
.form-stack .btn { justify-self: start; }
.field input[type="email"], .field input[type="text"] { height: 2.7rem; padding: 0 1rem; border-radius: 9999px; border: 1px solid var(--border); background-color: var(--background); font-size: 1rem; outline: none; width: 100%; }
.field input[type="email"]:focus, .field input[type="text"]:focus { border-color: rgba(31, 213, 249, .6); box-shadow: 0 0 0 4px rgba(31, 213, 249, .12); }
.inline-form { display: inline-flex; align-items: center; gap: .4rem; }
.select-compact { height: 2.2rem; padding: 0 2rem 0 .9rem; border-radius: 9999px; border: 1px solid var(--border); background-color: var(--background); font-size: .95rem; outline: none; color-scheme: dark; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 24 24' fill='none' stroke='%23ada89f' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right .7rem center; }
.btn-danger { color: var(--tone-error); }
.btn-danger:hover { color: var(--tone-error); background: rgba(243, 104, 150, .1); }
.alert-success { border-color: rgba(183, 226, 54, .35); background: rgba(183, 226, 54, .06); }
.alert-success .icon { color: var(--tone-success); }

.pagination { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 1rem; padding: 1.1rem 1.6rem; border-top: 1px solid var(--border); color: var(--muted-foreground); font-size: .95rem; }
.pagination-links { display: flex; gap: .35rem; align-items: center; }
.page-link { min-width: 2.4rem; height: 2.4rem; padding: 0 .7rem; display: inline-flex; align-items: center; justify-content: center; gap: .3rem; border-radius: 9999px; border: 1px solid var(--border); color: var(--foreground); font-variant-numeric: tabular-nums; }
.page-link:hover { background: var(--secondary); }
.page-link[aria-current="page"] { background: var(--foreground); color: var(--background); border-color: var(--foreground); }
.page-link[aria-disabled="true"] { opacity: .35; pointer-events: none; }

.empty { text-align: center; padding: 4rem 1.5rem; color: var(--muted-foreground); }
.empty .bubble { margin: 0 auto 1.25rem; }
.empty h3 { color: var(--foreground); font-size: 1.6rem; font-weight: 400; margin-bottom: .4rem; }

/* Liste des événements */

.event-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(21rem, 1fr)); gap: 1.25rem; }
.event-card { position: relative; display: flex; flex-direction: column; gap: 1.25rem; background: var(--card); border: 1px solid var(--border); border-radius: 1.75rem; padding: 1.6rem; transition: background-color .4s, border-color .4s, transform .4s var(--ease); overflow: hidden; isolation: isolate; }
.event-card::before { content: ""; position: absolute; inset: 0; z-index: -1; background: var(--gradient-hero); opacity: 0; transition: opacity .5s; }
a.event-card:hover { border-color: #3a3a3a; transform: translateY(-3px); }
a.event-card:hover::before { opacity: 1; }
.event-card-top { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.event-source { height: 26px; width: auto; }
.event-source-text { font-size: .75rem; text-transform: uppercase; letter-spacing: .14em; color: var(--muted-foreground); }
.event-card h3 { font-size: 1.85rem; font-weight: 400; line-height: 1.05; letter-spacing: -.01em; }
.event-card .manif { color: var(--muted-foreground); margin-top: .35rem; }
.event-meta { display: flex; flex-wrap: wrap; gap: .4rem 1rem; color: var(--muted-foreground); font-size: .95rem; }
.event-meta span { display: inline-flex; align-items: center; gap: .4rem; }
.event-numbers { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1px; background: var(--border); border-radius: 1rem; overflow: hidden; margin-top: auto; }
.event-numbers div { background: rgba(15, 15, 15, .6); padding: .75rem .9rem; }
.event-numbers b { display: block; font-size: 1.6rem; font-weight: 300; line-height: 1.1; font-variant-numeric: tabular-nums; }
.event-numbers span { font-size: .72rem; text-transform: uppercase; letter-spacing: .1em; color: var(--muted-foreground); }
.event-numbers .alert-number b { color: var(--tone-error); }
.event-go { display: inline-flex; align-items: center; gap: .35rem; color: var(--primary); font-size: 1rem; }
.event-card-muted { opacity: .7; }
.badge-soft { display: inline-flex; align-items: center; gap: .35rem; padding: .15rem .6rem; border-radius: 9999px; font-size: .8rem; letter-spacing: .06em; text-transform: uppercase; border: 1px solid var(--border); color: var(--muted-foreground); }
.badge-live { color: var(--tone-success); border-color: rgba(183, 226, 54, .35); }
.badge-live::before { content: ""; width: 6px; height: 6px; border-radius: 9999px; background: var(--tone-success); animation: pulse 2s infinite; }

.toolbar { display: flex; flex-wrap: wrap; gap: .75rem; align-items: center; justify-content: space-between; margin-bottom: 1.5rem; }
.toolbar .search input { height: 3rem; font-size: 1.15rem; padding-right: 1.25rem; }
.toolbar .search { flex: 1 1 22rem; max-width: 34rem; }

details.more { margin-top: 2.5rem; }
details.more summary { cursor: pointer; color: var(--muted-foreground); display: inline-flex; align-items: center; gap: .5rem; list-style: none; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary:hover { color: var(--foreground); }
details.more[open] summary .icon { transform: rotate(180deg); }
details.more .table-wrap { margin-top: 1rem; }

/* Détail d'un message */

.detail-grid { display: grid; grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr); gap: 1.5rem; align-items: start; }
.detail-grid > * { min-width: 0; }
@media (max-width: 1000px) { .detail-grid { grid-template-columns: 1fr; } }

.kv { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.1rem 1.5rem; }
.kv dt { font-size: .72rem; text-transform: uppercase; letter-spacing: .12em; color: var(--muted-foreground); }
.kv dd { margin: .2rem 0 0; font-size: 1.1rem; overflow-wrap: anywhere; }
.kv .wide { grid-column: 1 / -1; }
@media (max-width: 560px) { .kv { grid-template-columns: 1fr; } }

.section-label { font-size: .78rem; text-transform: uppercase; letter-spacing: .2em; color: var(--primary); margin: 1.75rem 0 1rem; display: flex; align-items: center; gap: .75rem; }
.section-label::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.panel > .section-label:first-child { margin-top: 0; }

.guest-list { display: grid; gap: .6rem; }
.guest { display: flex; align-items: center; gap: .9rem; padding: .7rem .9rem; border-radius: 1rem; background: rgba(255, 255, 255, .025); border: 1px solid var(--border); }
.guest-initials { width: 38px; height: 38px; border-radius: 9999px; display: grid; place-items: center; background: var(--secondary); font-size: .95rem; color: var(--primary); flex-shrink: 0; }
.guest b { font-weight: 500; font-size: 1.1rem; }
.guest span { display: block; color: var(--muted-foreground); font-size: .92rem; overflow-wrap: anywhere; }

.timeline { position: relative; display: grid; gap: 1.25rem; padding-left: 1.75rem; }
.timeline::before { content: ""; position: absolute; left: 6px; top: .45rem; bottom: .45rem; width: 1px; background: var(--border); }
.timeline li { position: relative; }
.timeline li::before { content: ""; position: absolute; left: -1.75rem; top: .4rem; width: 13px; height: 13px; border-radius: 9999px; background: var(--card); border: 2px solid #3a3a3a; }
.timeline li.done::before { border-color: var(--tone-success); background: var(--tone-success); }
.timeline li.error::before { border-color: var(--tone-error); background: var(--tone-error); }
.timeline li.current::before { border-color: var(--tone-pending); box-shadow: 0 0 0 4px rgba(250, 201, 56, .15); }
.timeline b { font-weight: 500; font-size: 1.1rem; display: block; }
.timeline span { color: var(--muted-foreground); font-size: .95rem; }

.error-box { border-radius: 1rem; border: 1px solid rgba(243, 104, 150, .35); background: rgba(243, 104, 150, .06); padding: 1rem 1.2rem; color: #f8b3c9; white-space: pre-wrap; overflow-wrap: anywhere; font-size: 1rem; }

.history { display: grid; gap: .4rem; }
.history a { display: grid; grid-template-columns: auto 1fr auto; gap: .75rem; align-items: center; padding: .6rem .8rem; border-radius: .9rem; border: 1px solid transparent; transition: background-color .2s, border-color .2s; }
.history a:hover { background: var(--secondary); }
.history a[aria-current="page"] { border-color: rgba(31, 213, 249, .45); background: rgba(31, 213, 249, .06); }
.history .seq { font-family: var(--font-serif); font-style: italic; font-size: 1.5rem; color: var(--muted-foreground); min-width: 2rem; }
.history small { display: block; color: var(--muted-foreground); font-size: .88rem; }

details.code { margin-top: 1.5rem; border: 1px solid var(--border); border-radius: 1.25rem; background: var(--card); overflow: hidden; }
details.code summary { cursor: pointer; padding: 1rem 1.4rem; display: flex; align-items: center; gap: .6rem; list-style: none; color: var(--muted-foreground); }
details.code summary::-webkit-details-marker { display: none; }
details.code summary:hover { color: var(--foreground); }
details.code summary .icon-chevron { margin-left: auto; transition: transform .2s; }
details.code[open] summary .icon-chevron { transform: rotate(180deg); }
details.code pre { margin: 0; padding: 1.25rem 1.4rem; border-top: 1px solid var(--border); max-height: 32rem; overflow: auto; font-family: var(--font-mono); font-size: .8rem; line-height: 1.55; color: #d6d2cb; background: #121212; white-space: pre; }

/* Connexion et pages simples */

.center-page { min-height: calc(100vh - 12rem); display: grid; place-items: center; padding: calc(var(--header-height) + 2rem) 1.5rem 2rem; }
.auth-card { position: relative; width: 100%; max-width: 30rem; text-align: center; border-radius: 2.25rem; border: 1px solid var(--border); background: var(--gradient-hero), var(--card); padding: 3rem 2.25rem; overflow: hidden; isolation: isolate; box-shadow: var(--shadow-card); }
.auth-card .orb { z-index: -1; }
.auth-card img.symbol { width: 96px; height: auto; margin: 0 auto 1.5rem; }
.auth-card h1 { font-size: 2.6rem; font-weight: 300; line-height: 1; letter-spacing: -.02em; }
.auth-card p { margin-top: 1rem; color: var(--muted-foreground); font-size: 1.08rem; }
.auth-card .btn { margin-top: 2rem; width: 100%; }
.auth-card .fine { margin-top: 1.25rem; font-size: .9rem; }

@media (max-width: 640px) {
    .container { padding-left: 1rem; padding-right: 1rem; }
    .section { padding: 4.5rem 0; }
    .gw-header { padding: .75rem 1rem 0; }
    .search input { font-size: 1.1rem; padding-right: 1rem; }
    .search-hint .search-mode { display: none; }
    .filter-actions { margin-left: 0; }
    .field, .field select, .field input[type="date"] { width: 100%; }
    .filter-row > * { flex: 1 1 100%; }
    .panel { padding: 1.2rem; border-radius: 1.4rem; }
    .results-head, .pagination { padding: 1rem 1.2rem; }
    .table th, .table td { padding: .7rem .8rem; }
}
