/*
 * theme_gescom.css — habille l'assistant IA (assistant.css, commun avec la Comptabilité) aux couleurs de Gescom.
 * Les variables sont limitées aux éléments de l'assistant (.ia-theme) : aucune page de Gescom n'est touchée.
 */
.ia-theme {
    --fond: #f1f5f9;
    --carte: #ffffff;
    --texte: #0f172a;
    --texte-2: #475569;
    --texte-3: #94a3b8;
    --bord: #e2e8f0;
    --bord-2: #cbd5e1;
    --survol: #f8fafc;
    --tete-table: #f1f5f9;
    --total: #eef2f6;
    /* accent de l'assistant = bleu de Gescom (le vert reste celui de la Comptabilité) */
    --vert: #2563eb;
    --vert-fonce: #1d4ed8;
    --vert-doux: #eff6ff;
    --bleu: #2563eb;
    --ia-marque-fond: #2563eb;
    --ia-marque-point: #93c5fd;
    --rouge: #b42318;
    --rayon: 6px;
    --police: 'Poppins', 'Segoe UI', Arial, sans-serif;
    --hauteur-entete: 0px;
    font-family: var(--police);
    color: var(--texte);
    font-size: 14px;
    line-height: 1.5;
}
/* mode sombre : fond NOIR (pas de bleu nuit), quelle que soit la façon dont la page le note */
body.dark-mode .ia-theme, body.dark .ia-theme, html[data-theme="dark"] .ia-theme {
    --fond: #000000;
    --carte: #0a0a0a;
    --texte: #f5f5f5;
    --texte-2: #d4d4d4;
    --texte-3: #a3a3a3;
    --bord: #262626;
    --bord-2: #3a3a3a;
    --survol: #171717;
    --tete-table: #111111;
    --total: #171717;
    --vert: #3b82f6;
    --vert-fonce: #2563eb;
    --vert-doux: #0b1730;
    --rouge: #f87171;
}
.ia-theme *, .ia-theme *::before, .ia-theme *::after { box-sizing: border-box; }
.ia-theme a { color: var(--bleu); text-decoration: none; }
.ia-theme button, .ia-theme textarea { font-family: var(--police); }

/* panneau sur toute la hauteur dans Gescom */
.ia-panneau.ia-theme { top: 0; z-index: 1200; }
.ia-lanceur.ia-theme { z-index: 1150; }

/* page dédiée dans le cadre commun de Gescom */
.ia-page.ia-theme { height: calc(100vh - var(--as-entete, 62px) - 40px); }

/* boutons et badges utilisés par l'assistant (repris de la Comptabilité) */
.ia-theme .btn { display: inline-flex; align-items: center; justify-content: center; gap: 7px; padding: 7px 13px; border-radius: var(--rayon);
    border: 1px solid var(--bord-2); background: var(--carte); color: var(--texte); font: 500 13.5px var(--police); cursor: pointer; text-decoration: none; }
.ia-theme .btn:hover { background: var(--survol); text-decoration: none; }
.ia-theme .btn .ic { font-size: 16px; }
.ia-theme .btn-principal { background: var(--vert); border-color: var(--vert); color: #fff; }
.ia-theme .btn-principal:hover { background: var(--vert-fonce); }
.ia-theme .btn-leger { border-color: transparent; background: transparent; color: var(--texte-2); }
.ia-theme .btn-petit { padding: 5px 9px; font-size: 12.5px; }
.ia-theme .btn:disabled { opacity: .45; cursor: not-allowed; }
.ia-theme .badge { display: inline-flex; align-items: center; gap: 5px; padding: 1px 8px; border-radius: 4px; font-size: 11.5px; font-weight: 600;
    border: 1px solid #c7cdd4; background: #f4f6f8; color: #3f4752; white-space: nowrap; }
.ia-theme .badge-ok { color: #166534; border-color: #86c79e; background: #f0f8f3; }
.ia-theme h2, .ia-theme h3, .ia-theme h4 { color: var(--texte); }

/* agent ouvert : le bouton flottant « Contacter l'assistance » s'efface pour ne pas couvrir la zone de saisie */
body.ia-ouvert .contact-fab, body.ia-ouvert #contactFab { opacity: 0; pointer-events: none; }

/* bouton de lancement aux couleurs de Gescom (bleu, comme ses boutons) */
.ia-lanceur.ia-theme { background: #2563eb; border-color: #2563eb; }
.ia-lanceur.ia-theme:hover { background: #1d4ed8; }
.ia-lanceur.ia-theme, .ia-lanceur.ia-theme span { color: #fff !important; font-weight: 600; }
.ia-lanceur.ia-theme .ic { color: #fff !important; background-color: #fff; }
