/* ── AJ Optimize CRM – Frontend CSS ─────────────────────────────────────── */

.ajcrm-espace   { padding:40px 20px; min-height:60vh; }
.ajcrm-container { max-width:1040px; margin:0 auto; }

/* Gate connexion */
.ajcrm-login-gate { display:flex; justify-content:center; align-items:center; min-height:50vh; }
.ajcrm-login-card { text-align:center; background:#fff; border:1px solid #e0e0e0; border-radius:16px; padding:56px 40px; max-width:400px; box-shadow:0 4px 24px rgba(0,0,0,.08); }
.ajcrm-login-logo { font-size:3.5rem; margin-bottom:16px; }
.ajcrm-login-card h1 { font-size:1.8rem; margin:0 0 10px; }
.ajcrm-login-card p  { color:#666; margin:0 0 24px; }

/* Header espace */
.ajcrm-ec-header { display:flex; justify-content:space-between; align-items:center; margin-bottom:32px; flex-wrap:wrap; gap:16px; }
.ajcrm-ec-identity { display:flex; align-items:center; gap:16px; }
.ajcrm-ec-avatar { width:64px; height:64px; flex-shrink:0; }
.ajcrm-ec-avatar img { width:64px; height:64px; border-radius:50%; object-fit:cover; border:3px solid #e0e0e0; }
.ajcrm-avatar-init { display:flex; align-items:center; justify-content:center; width:64px; height:64px; border-radius:50%; background:linear-gradient(135deg,#2271b1,#135e96); color:#fff; font-size:1.6rem; font-weight:800; }
.ajcrm-ec-identity h1 { font-size:1.5rem; margin:0 0 4px; }
.ajcrm-ec-company  { margin:2px 0; font-weight:600; color:#444; font-size:14px; }
.ajcrm-ec-subtitle { margin:2px 0 0; color:#888; font-size:13px; }

/* Notice */
.ajcrm-notice { padding:12px 16px; border-radius:8px; margin-bottom:20px; font-size:13px; }
.ajcrm-notice-warn { background:#fff3cd; border:1px solid #ffc107; color:#856404; }

/* Onglets */
.ajcrm-tabs { display:flex; gap:4px; border-bottom:2px solid #e0e0e0; margin-bottom:28px; flex-wrap:wrap; }
.ajcrm-tab { display:flex; align-items:center; gap:6px; padding:10px 18px; border-radius:6px 6px 0 0; text-decoration:none; font-size:14px; font-weight:600; color:#555; transition:all .2s; border-bottom:3px solid transparent; margin-bottom:-2px; }
.ajcrm-tab:hover { color:#2271b1; background:#f0f6fc; }
.ajcrm-tab-active { color:#2271b1; border-bottom-color:#2271b1; background:#f0f6fc; }

/* Tab content */
.ajcrm-tab-content { animation:ajcrm-fadein .2s ease; }
@keyframes ajcrm-fadein { from{opacity:0;transform:translateY(6px)} to{opacity:1;transform:none} }

/* Empty state */
.ajcrm-empty-state { text-align:center; padding:60px 20px; background:#f9f9f9; border-radius:12px; border:2px dashed #ddd; }
.ajcrm-empty-icon { font-size:3rem; margin-bottom:12px; }
.ajcrm-empty-state h2 { font-size:1.3rem; margin-bottom:8px; }
.ajcrm-empty-state p  { color:#777; margin:0; }

/* Projets */
.ajcrm-projets-grid { display:grid; grid-template-columns:repeat(auto-fill,minmax(300px,1fr)); gap:20px; }
.ajcrm-projet-card { background:#fff; border:1px solid #e0e0e0; border-radius:12px; border-top:4px solid; padding:22px; box-shadow:0 2px 8px rgba(0,0,0,.06); transition:box-shadow .2s,transform .2s; }
.ajcrm-projet-card:hover { box-shadow:0 6px 20px rgba(0,0,0,.1); transform:translateY(-2px); }
.ajcrm-projet-head { display:flex; justify-content:space-between; align-items:flex-start; gap:10px; margin-bottom:10px; }
.ajcrm-projet-head h3 { margin:0; font-size:1rem; font-weight:700; color:#1d2327; flex:1; }
.ajcrm-projet-desc { font-size:13px; color:#555; margin:0 0 12px; }
.ajcrm-projet-meta { display:flex; flex-direction:column; gap:4px; margin-bottom:16px; }
.ajcrm-projet-meta span { font-size:12px; color:#666; }
.ajcrm-progress-wrap { }
.ajcrm-progress-label { display:flex; justify-content:space-between; font-size:12px; color:#666; margin-bottom:6px; }
.ajcrm-progress-label strong { color:#1d2327; }
.ajcrm-progress-track { background:#eee; border-radius:6px; height:8px; overflow:hidden; }
.ajcrm-progress-fill  { height:8px; border-radius:6px; transition:width .4s ease; }

/* Fichiers */
.ajcrm-fichiers-list { display:flex; flex-direction:column; gap:12px; }
.ajcrm-fichier-row { display:flex; align-items:center; gap:16px; background:#fff; border:1px solid #e0e0e0; border-radius:10px; padding:16px 20px; transition:box-shadow .2s; }
.ajcrm-fichier-row:hover { box-shadow:0 3px 12px rgba(0,0,0,.08); }
.ajcrm-fichier-row.ajcrm-expired { opacity:.6; background:#fafafa; }
.ajcrm-fichier-icon { font-size:2.2rem; flex-shrink:0; }
.ajcrm-fichier-info { flex:1; display:flex; flex-direction:column; gap:4px; min-width:0; }
.ajcrm-fichier-info strong { font-size:15px; font-weight:700; color:#1d2327; }
.ajcrm-fichier-desc { font-size:13px; color:#555; }
.ajcrm-fichier-meta { display:flex; flex-wrap:wrap; gap:10px; }
.ajcrm-fichier-meta span { font-size:12px; color:#777; }
.ajcrm-meta-expired { color:#dc3545; font-weight:600; }
.ajcrm-fichier-action { flex-shrink:0; }

/* Chat */
.ajcrm-chat-wrap { background:#fff; border:1px solid #e0e0e0; border-radius:12px; overflow:hidden; }
.ajcrm-chat-messages { padding:20px; min-height:320px; max-height:480px; overflow-y:auto; display:flex; flex-direction:column; gap:12px; background:#f8f9fa; }
.ajcrm-chat-loading  { text-align:center; color:#999; font-size:13px; padding:20px; }
.ajcrm-chat-bubble { max-width:72%; padding:10px 15px; border-radius:12px; font-size:14px; line-height:1.5; white-space:pre-wrap; }
.ajcrm-bubble-admin  { background:#e3f0ff; align-self:flex-start; border-bottom-left-radius:3px; }
.ajcrm-bubble-client { background:#2271b1; color:#fff; align-self:flex-end; border-bottom-right-radius:3px; }
.ajcrm-bubble-meta   { font-size:11px; opacity:.7; margin-top:4px; }
.ajcrm-chat-form { display:flex; gap:12px; padding:18px; border-top:1px solid #e0e0e0; align-items:flex-end; background:#fff; }
.ajcrm-chat-form textarea { flex:1; width:100%; min-height:96px; max-height:220px; border:1px solid #dcdcde; border-radius:12px; padding:14px 16px; font-size:15px; line-height:1.5; resize:vertical; font-family:inherit; box-sizing:border-box; background:#fff; }
.ajcrm-chat-form textarea:focus { border-color:#2271b1; outline:none; box-shadow:0 0 0 3px rgba(34,113,177,.14); }
.ajcrm-chat-form .ajcrm-btn { min-height:48px; }

/* Profil */
.ajcrm-profil-grid { display:grid; grid-template-columns:1fr 1fr; gap:20px; }
.ajcrm-profil-card { background:#fff; border:1px solid #e0e0e0; border-radius:12px; padding:24px; }
.ajcrm-profil-card h3 { margin:0 0 18px; font-size:1rem; color:#1d2327; }
.ajcrm-dl { margin:0; }
.ajcrm-dl-row { display:flex; padding:10px 0; border-bottom:1px solid #f0f0f1; gap:12px; }
.ajcrm-dl-row:last-child { border-bottom:none; }
.ajcrm-dl-row dt { font-weight:600; font-size:13px; color:#555; min-width:120px; flex-shrink:0; }
.ajcrm-dl-row dd { font-size:13px; color:#1d2327; margin:0; }
.ajcrm-profil-notice { font-size:12px; color:#888; margin-top:16px; font-style:italic; }

/* Boutons */
.ajcrm-btn { display:inline-flex; align-items:center; gap:6px; padding:9px 18px; border-radius:6px; font-size:14px; font-weight:600; text-decoration:none; cursor:pointer; border:none; transition:all .2s; white-space:nowrap; }
.ajcrm-btn-lg { padding:13px 28px; font-size:16px; }
.ajcrm-btn:active { transform:scale(.97); }
.ajcrm-btn-primary { background:#2271b1; color:#fff; }
.ajcrm-btn-primary:hover { background:#135e96; color:#fff; }
.ajcrm-btn-outline { background:transparent; color:#2271b1; border:2px solid #2271b1; }
.ajcrm-btn-outline:hover { background:#f0f6fc; }
.ajcrm-btn-disabled { background:#ddd; color:#999; cursor:not-allowed; }

/* Badge */
.ajcrm-badge { display:inline-block; padding:3px 10px; border-radius:20px; font-size:12px; font-weight:600; color:#fff; }

@media (max-width:720px) {
    .ajcrm-ec-header   { flex-direction:column; align-items:flex-start; }
    .ajcrm-tabs        { gap:2px; }
    .ajcrm-tab         { padding:8px 12px; font-size:12px; }
    .ajcrm-projets-grid{ grid-template-columns:1fr; }
    .ajcrm-fichier-row { flex-direction:column; align-items:flex-start; }
    .ajcrm-profil-grid { grid-template-columns:1fr; }
    .ajcrm-chat-form   { flex-direction:column; align-items:stretch; }
}

/* ── Fichiers dans les projets ───────────────────────────────────────────── */
.ajcrm-projet-files { margin-top: 16px; padding-top: 16px; border-top: 1px solid #f0f0f0; }
.ajcrm-files-title { font-size: 13px; font-weight: 600; color: #555; margin: 0 0 10px; }
.ajcrm-files-grid { display: flex; flex-direction: column; gap: 6px; }
.ajcrm-file-chip {
    display: flex; align-items: center; gap: 10px;
    padding: 9px 14px; border-radius: 8px;
    background: #f6f7f7; border: 1px solid #e8e8e8;
    text-decoration: none; color: inherit;
    transition: background .15s, border-color .15s;
    font-size: 13px;
}
.ajcrm-file-chip:hover { background: #e8f0fe; border-color: #2271b1; color: #2271b1; }
.ajcrm-chip-name { flex: 1; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.ajcrm-chip-size { font-size: 11px; color: #999; white-space: nowrap; }

/* Hélios CRM v2.0.1 – profil éditable & notifications */
.ajcrm-tab-count{
    display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;margin-left:6px;border-radius:999px;background:#d63638;color:#fff;font-size:12px;font-weight:700;line-height:1;width:fit-content;
}
.ajcrm-profil-card-main{grid-column:span 2;}
.ajcrm-profile-form{display:flex;flex-direction:column;gap:20px;}
.ajcrm-profile-avatar{display:flex;align-items:center;gap:18px;padding:16px;border:1px solid var(--ajcrm-border,#e5e7eb);border-radius:16px;background:#f8fafc;}
.ajcrm-profile-avatar-preview{width:74px;height:74px;border-radius:18px;overflow:hidden;background:#2271b1;color:#fff;display:flex;align-items:center;justify-content:center;font-size:28px;font-weight:800;flex:0 0 auto;}
.ajcrm-profile-avatar-preview img{width:100%;height:100%;object-fit:cover;display:block;}
.ajcrm-profile-avatar small{display:block;margin-top:8px;color:#64748b;}
.ajcrm-profile-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px;}
.ajcrm-profile-field{display:flex;flex-direction:column;gap:6px;font-size:14px;font-weight:600;color:#334155;}
.ajcrm-profile-field input{width:100%;border:1px solid #d8dee8;border-radius:10px;padding:11px 12px;font-size:15px;background:#fff;}
.ajcrm-profile-field input:disabled{background:#f1f5f9;color:#64748b;cursor:not-allowed;}
.ajcrm-profile-field small{font-weight:400;color:#64748b;}
.ajcrm-profile-actions{display:flex;align-items:center;gap:12px;flex-wrap:wrap;}
.ajcrm-profile-message{font-size:14px;font-weight:600;}
.ajcrm-profile-message.is-success{color:#198754;}
.ajcrm-profile-message.is-error{color:#d63638;}
@media (max-width:760px){.ajcrm-profil-card-main{grid-column:auto}.ajcrm-profile-fields{grid-template-columns:1fr}.ajcrm-profile-avatar{align-items:flex-start;flex-direction:column}}

/* Hélios CRM v2.0.4 – formulaire de connexion front */
.ajcrm-login-card { width:100%; }
.ajcrm-login-card h2 { font-size:1.8rem; margin:0 0 10px; color:#1d2327; }
.ajcrm-login-card-compact { max-width:460px; }
.ajcrm-login-card-connected { max-width:460px; }
.ajcrm-login-form { display:flex; flex-direction:column; gap:16px; margin-top:22px; text-align:left; }
.ajcrm-login-field { display:flex; flex-direction:column; gap:7px; font-size:14px; font-weight:700; color:#334155; }
.ajcrm-login-field input { width:100%; border:1px solid #d8dee8; border-radius:12px; padding:13px 14px; font-size:15px; line-height:1.4; background:#fff; box-sizing:border-box; }
.ajcrm-login-field input:focus { border-color:#2271b1; outline:none; box-shadow:0 0 0 3px rgba(34,113,177,.14); }
.ajcrm-login-options { display:flex; align-items:center; justify-content:space-between; gap:12px; flex-wrap:wrap; font-size:13px; }
.ajcrm-login-options a { color:#2271b1; text-decoration:none; font-weight:600; }
.ajcrm-login-options a:hover { text-decoration:underline; }
.ajcrm-login-remember { display:inline-flex; align-items:center; gap:8px; color:#475569; font-weight:500; }
.ajcrm-login-remember input { margin:0; }
.ajcrm-login-submit { width:100%; justify-content:center; }
.ajcrm-login-error { margin:18px 0 0; padding:11px 13px; border-radius:10px; background:#fff1f1; border:1px solid #f4b8b8; color:#b42318; font-size:13px; font-weight:700; text-align:left; }
.ajcrm-login-help { margin:18px 0 0 !important; color:#64748b !important; font-size:13px; }

/* Compatibilité ancien markup chat compose */
.ajcrm-chat-compose { display:flex; gap:12px; padding:18px; border-top:1px solid #e0e0e0; align-items:flex-end; background:#fff; }
.ajcrm-chat-compose textarea { flex:1; width:100%; min-height:110px; max-height:240px; border:1px solid #dcdcde; border-radius:12px; padding:14px 16px; font-size:15px; line-height:1.5; resize:vertical; font-family:inherit; box-sizing:border-box; background:#fff; }
.ajcrm-chat-compose textarea:focus { border-color:#2271b1; outline:none; box-shadow:0 0 0 3px rgba(34,113,177,.14); }
.ajcrm-chat-compose .ajcrm-btn { min-height:48px; }
@media (max-width:720px){.ajcrm-login-card{padding:40px 24px}.ajcrm-chat-compose{flex-direction:column;align-items:stretch}.ajcrm-login-options{align-items:flex-start;flex-direction:column}}

/* Hélios CRM v2.0.5 – Interface projets moderne */
.ajcrm-projects-overview{
    display:flex;
    align-items:flex-end;
    justify-content:space-between;
    gap:24px;
    margin:0 0 24px;
    padding:26px;
    border:1px solid #e5e7eb;
    border-radius:22px;
    background:linear-gradient(135deg,#ffffff 0%,#f8fbff 100%);
    box-shadow:0 18px 45px rgba(15,23,42,.06);
}
.ajcrm-projects-overview h2{
    margin:4px 0 8px;
    font-size:clamp(1.35rem,2.4vw,2rem);
    line-height:1.15;
    letter-spacing:-.03em;
    color:#111827;
}
.ajcrm-projects-overview p{
    max-width:640px;
    margin:0;
    color:#64748b;
    font-size:15px;
    line-height:1.6;
}
.ajcrm-eyebrow{
    display:inline-flex;
    align-items:center;
    gap:8px;
    font-size:12px;
    font-weight:800;
    letter-spacing:.08em;
    text-transform:uppercase;
    color:#2271b1;
}
.ajcrm-eyebrow:before{
    content:"";
    width:8px;
    height:8px;
    border-radius:999px;
    background:#2271b1;
    box-shadow:0 0 0 5px rgba(34,113,177,.12);
}
.ajcrm-projects-stats{
    display:flex;
    gap:10px;
    flex:0 0 auto;
    flex-wrap:wrap;
    justify-content:flex-end;
}
.ajcrm-projects-stats span{
    min-width:104px;
    padding:14px 16px;
    border:1px solid #e2e8f0;
    border-radius:16px;
    background:#fff;
    color:#64748b;
    font-size:12px;
    font-weight:700;
    text-align:center;
    box-shadow:0 10px 24px rgba(15,23,42,.05);
}
.ajcrm-projects-stats strong{
    display:block;
    margin-bottom:2px;
    color:#0f172a;
    font-size:24px;
    line-height:1;
}
.ajcrm-projets-grid-modern{
    display:grid;
    grid-template-columns:repeat(auto-fit,minmax(min(100%,340px),1fr));
    gap:22px;
    align-items:stretch;
}
.ajcrm-projet-card-modern{
    position:relative;
    display:flex;
    flex-direction:column;
    gap:18px;
    min-height:100%;
    padding:24px;
    overflow:hidden;
    border:1px solid #e5e7eb;
    border-top:1px solid #e5e7eb;
    border-radius:22px;
    background:rgba(255,255,255,.96);
    box-shadow:0 18px 44px rgba(15,23,42,.07);
    transition:transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.ajcrm-projet-card-modern:hover{
    transform:translateY(-4px);
    border-color:rgba(34,113,177,.28);
    box-shadow:0 24px 60px rgba(15,23,42,.12);
}
.ajcrm-projet-card-modern:before{
    content:"";
    position:absolute;
    inset:-80px -90px auto auto;
    width:190px;
    height:190px;
    border-radius:999px;
    background:color-mix(in srgb, var(--projet-color) 12%, transparent);
    pointer-events:none;
}
.ajcrm-projet-accent{
    position:absolute;
    inset:0 auto 0 0;
    width:5px;
    background:var(--projet-color,#2271b1);
}
.ajcrm-projet-head-modern{
    position:relative;
    z-index:1;
    display:flex;
    align-items:flex-start;
    justify-content:space-between;
    gap:16px;
    margin:0;
}
.ajcrm-projet-title-wrap{
    display:flex;
    align-items:flex-start;
    gap:13px;
    min-width:0;
}
.ajcrm-projet-icon{
    width:42px;
    height:42px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    flex:0 0 auto;
    border-radius:14px;
    background:#f1f5f9;
    font-size:20px;
}
.ajcrm-projet-head-modern h3{
    margin:0 0 4px;
    color:#0f172a;
    font-size:1.08rem;
    line-height:1.25;
    letter-spacing:-.015em;
}
.ajcrm-projet-ref{
    display:block;
    color:#94a3b8;
    font-size:12px;
    font-weight:700;
}
.ajcrm-status-badge{
    position:relative;
    z-index:1;
    padding:7px 11px;
    border-radius:999px;
    box-shadow:0 8px 18px rgba(15,23,42,.12);
    white-space:nowrap;
}
.ajcrm-projet-desc-modern{
    position:relative;
    z-index:1;
    margin:0;
    padding:14px 16px;
    border:1px solid #edf2f7;
    border-radius:16px;
    background:#f8fafc;
    color:#475569;
    font-size:14px;
    line-height:1.6;
}
.ajcrm-projet-meta-grid{
    position:relative;
    z-index:1;
    display:grid;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:10px;
    margin:0;
}
.ajcrm-projet-meta-item{
    display:grid;
    grid-template-columns:auto 1fr;
    column-gap:10px;
    row-gap:2px;
    min-width:0;
    padding:13px;
    border:1px solid #e8eef6;
    border-radius:16px;
    background:#fff;
}
.ajcrm-meta-icon{
    grid-row:1 / span 2;
    width:30px;
    height:30px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:10px;
    background:#f8fafc;
}
.ajcrm-meta-label{
    color:#94a3b8;
    font-size:11px;
    font-weight:800;
    letter-spacing:.04em;
    text-transform:uppercase;
}
.ajcrm-projet-meta-item strong{
    min-width:0;
    overflow:hidden;
    color:#0f172a;
    font-size:13px;
    font-weight:800;
    text-overflow:ellipsis;
    white-space:nowrap;
}
.ajcrm-priority-urgent{border-color:#fecaca;background:#fff7f7;}
.ajcrm-priority-high{border-color:#fed7aa;background:#fffaf5;}
.ajcrm-priority-normal{border-color:#bfdbfe;background:#f8fbff;}
.ajcrm-priority-low{border-color:#bbf7d0;background:#f8fff9;}
.ajcrm-projet-files{
    position:relative;
    z-index:1;
    margin-top:auto;
    padding-top:18px;
    border-top:1px solid #edf2f7;
}
.ajcrm-files-head{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:12px;
    margin-bottom:12px;
}
.ajcrm-files-head span{
    color:#94a3b8;
    font-size:12px;
    font-weight:700;
}
.ajcrm-files-title{
    margin:0;
    color:#0f172a;
    font-size:14px;
    font-weight:800;
}
.ajcrm-files-grid-modern{
    display:grid;
    grid-template-columns:1fr;
    gap:9px;
}
.ajcrm-file-chip-modern{
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:12px;
    padding:12px;
    border:1px solid #e8eef6;
    border-radius:16px;
    background:#fff;
    color:#0f172a;
    text-decoration:none;
    transition:transform .15s ease, border-color .15s ease, background .15s ease;
}
.ajcrm-file-chip-modern:hover{
    transform:translateY(-1px);
    border-color:#2271b1;
    background:#f8fbff;
    color:#0f172a;
}
.ajcrm-chip-icon{
    width:38px;
    height:38px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:12px;
    background:#f1f5f9;
    font-size:18px;
}
.ajcrm-chip-content{
    display:flex;
    flex-direction:column;
    gap:2px;
    min-width:0;
}
.ajcrm-file-chip-modern .ajcrm-chip-name{
    display:block;
    min-width:0;
    overflow:hidden;
    color:#0f172a;
    font-size:13px;
    font-weight:800;
    text-overflow:ellipsis;
    white-space:nowrap;
}
.ajcrm-file-chip-modern .ajcrm-chip-size{
    color:#94a3b8;
    font-size:12px;
    font-weight:700;
}
.ajcrm-chip-action{
    padding:7px 10px;
    border-radius:999px;
    background:#eef6ff;
    color:#2271b1;
    font-size:12px;
    font-weight:800;
}
.ajcrm-files-empty-text{
    margin:0;
    padding:13px 14px;
    border:1px dashed #d8dee8;
    border-radius:14px;
    background:#f8fafc;
    color:#64748b;
    font-size:13px;
}
@supports not (background:color-mix(in srgb, #000 10%, transparent)){
    .ajcrm-projet-card-modern:before{background:rgba(34,113,177,.08);}
}
@media (max-width:860px){
    .ajcrm-projects-overview{align-items:flex-start;flex-direction:column;padding:22px;}
    .ajcrm-projects-stats{justify-content:flex-start;width:100%;}
    .ajcrm-projects-stats span{flex:1;min-width:130px;}
}
@media (max-width:520px){
    .ajcrm-projet-card-modern{padding:20px;border-radius:18px;}
    .ajcrm-projet-head-modern{flex-direction:column;}
    .ajcrm-status-badge{align-self:flex-start;}
    .ajcrm-projet-meta-grid{grid-template-columns:1fr;}
    .ajcrm-file-chip-modern{grid-template-columns:auto minmax(0,1fr);}
    .ajcrm-chip-action{grid-column:1 / -1;text-align:center;}
}

/* Hélios CRM v2.0.6 – Dépôt de fichiers client */
.ajcrm-files-section + .ajcrm-files-section{margin-top:18px;padding-top:18px;border-top:1px dashed #dbe4ef;}
.ajcrm-files-section-client{padding:16px;border:1px solid #e8eef6;border-radius:18px;background:#fbfdff;}
.ajcrm-file-source-client{border-style:dashed;background:#fff;}
.ajcrm-file-source-client .ajcrm-chip-action{background:#f1f5f9;color:#475569;}
.ajcrm-client-upload-form{display:grid;grid-template-columns:minmax(0,1fr) auto;gap:12px;align-items:center;margin-top:14px;}
.ajcrm-client-upload-zone{display:flex;align-items:center;gap:12px;min-width:0;padding:14px;border:1px dashed #b9cce1;border-radius:16px;background:#fff;cursor:pointer;transition:border-color .15s ease,background .15s ease,transform .15s ease;}
.ajcrm-client-upload-zone:hover{border-color:#2271b1;background:#f8fbff;transform:translateY(-1px);}
.ajcrm-client-upload-zone input{display:none;}
.ajcrm-client-upload-icon{width:38px;height:38px;display:inline-flex;align-items:center;justify-content:center;flex:0 0 auto;border-radius:12px;background:#eef6ff;font-size:18px;}
.ajcrm-client-upload-text{display:flex;flex-direction:column;gap:2px;min-width:0;color:#0f172a;font-size:14px;}
.ajcrm-client-upload-text strong{font-weight:800;}
.ajcrm-client-upload-text small{color:#64748b;font-size:12px;line-height:1.35;}
.ajcrm-client-upload-submit{white-space:nowrap;}
.ajcrm-client-upload-feedback{grid-column:1 / -1;min-height:18px;color:#64748b;font-size:13px;font-weight:700;}
.ajcrm-client-upload-feedback.is-success{color:#198754;}
.ajcrm-client-upload-feedback.is-error{color:#d63638;}
.ajcrm-client-upload-feedback.is-info{color:#2271b1;}
@media (max-width:620px){.ajcrm-client-upload-form{grid-template-columns:1fr}.ajcrm-client-upload-submit{width:100%;justify-content:center}.ajcrm-client-upload-zone{align-items:flex-start}}

/* Hélios CRM v2.0.7 – Layout SaaS sidebar + lightbox fichiers */
.ajcrm-espace{
    min-height:100vh;
    padding:24px;
    background:#f3f6fb;
    box-sizing:border-box;
}
.ajcrm-app-shell{
    display:grid;
    grid-template-columns:280px minmax(0,1fr);
    gap:24px;
    max-width:1440px;
    margin:0 auto;
    align-items:start;
}
.ajcrm-sidebar{
    position:sticky;
    top:24px;
    display:flex;
    flex-direction:column;
    min-height:calc(100vh - 48px);
    padding:18px;
    border:1px solid #e2e8f0;
    border-radius:28px;
    background:rgba(255,255,255,.92);
    box-shadow:0 22px 60px rgba(15,23,42,.08);
    backdrop-filter:blur(14px);
}
.ajcrm-back-site{
    display:inline-flex;
    align-items:center;
    gap:8px;
    width:fit-content;
    padding:9px 12px;
    border-radius:999px;
    background:#f8fafc;
    color:#475569;
    text-decoration:none;
    font-size:13px;
    font-weight:800;
    transition:background .15s ease,color .15s ease,transform .15s ease;
}
.ajcrm-back-site:hover{background:#eef6ff;color:#2271b1;transform:translateX(-2px);}
.ajcrm-sidebar-profile{
    display:flex;
    align-items:center;
    gap:13px;
    margin:18px 0 22px;
    padding:14px;
    border:1px solid #edf2f7;
    border-radius:22px;
    background:linear-gradient(135deg,#fff,#f8fbff);
}
.ajcrm-sidebar-profile .ajcrm-ec-avatar,
.ajcrm-sidebar-profile .ajcrm-ec-avatar img,
.ajcrm-sidebar-profile .ajcrm-avatar-init{width:54px;height:54px;}
.ajcrm-sidebar-profile .ajcrm-avatar-init{font-size:1.25rem;}
.ajcrm-sidebar-profile-text{min-width:0;display:flex;flex-direction:column;gap:2px;}
.ajcrm-sidebar-hello{color:#94a3b8;font-size:12px;font-weight:800;text-transform:uppercase;letter-spacing:.05em;}
.ajcrm-sidebar-profile-text strong{overflow:hidden;color:#0f172a;font-size:15px;line-height:1.25;text-overflow:ellipsis;white-space:nowrap;}
.ajcrm-sidebar-profile-text small{overflow:hidden;color:#64748b;font-size:13px;text-overflow:ellipsis;white-space:nowrap;}
.ajcrm-sidebar-tabs{
    display:flex;
    flex-direction:column;
    gap:8px;
    margin:0;
    border:0;
}
.ajcrm-sidebar-tabs .ajcrm-tab{
    display:grid;
    grid-template-columns:auto minmax(0,1fr) auto;
    align-items:center;
    gap:10px;
    margin:0;
    padding:13px 14px;
    border:1px solid transparent;
    border-radius:16px;
    color:#475569;
    background:transparent;
    font-size:14px;
    font-weight:850;
}
.ajcrm-sidebar-tabs .ajcrm-tab:hover{background:#f8fafc;color:#2271b1;border-color:#e2e8f0;}
.ajcrm-sidebar-tabs .ajcrm-tab-active{
    background:#eef6ff;
    border-color:#cde3fb;
    color:#155f9d;
    box-shadow:0 10px 24px rgba(34,113,177,.08);
}
.ajcrm-tab-icon{width:28px;height:28px;display:inline-flex;align-items:center;justify-content:center;border-radius:10px;background:#fff;box-shadow:inset 0 0 0 1px #edf2f7;}
.ajcrm-tab-label{min-width:0;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;}
.ajcrm-sidebar-footer{margin-top:auto;padding-top:18px;}
.ajcrm-sidebar-logout{width:100%;justify-content:center;}
.ajcrm-main-panel{
    min-width:0;
    padding:28px;
    border:1px solid #e2e8f0;
    border-radius:30px;
    background:#fff;
    box-shadow:0 22px 60px rgba(15,23,42,.06);
}
.ajcrm-mobile-topbar{display:none;}
.ajcrm-main-panel .ajcrm-projects-overview{margin-top:0;}
.ajcrm-main-panel .ajcrm-tab-content{animation:ajcrm-fadein .2s ease;}

/* Lightbox */
.ajcrm-lightbox{position:fixed;inset:0;z-index:999999;display:none;align-items:center;justify-content:center;padding:24px;}
.ajcrm-lightbox.is-open{display:flex;}
.ajcrm-lightbox-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.72);backdrop-filter:blur(8px);}
.ajcrm-lightbox-dialog{position:relative;z-index:1;display:flex;flex-direction:column;width:min(1100px,100%);height:min(82vh,860px);border:1px solid rgba(255,255,255,.16);border-radius:24px;background:#fff;box-shadow:0 30px 100px rgba(0,0,0,.35);overflow:hidden;}
.ajcrm-lightbox-header,.ajcrm-lightbox-footer{display:flex;align-items:center;justify-content:space-between;gap:12px;padding:14px 16px;border-bottom:1px solid #e2e8f0;background:#fff;}
.ajcrm-lightbox-footer{justify-content:flex-end;border-top:1px solid #e2e8f0;border-bottom:0;}
.ajcrm-lightbox-header strong{min-width:0;overflow:hidden;color:#0f172a;font-size:15px;text-overflow:ellipsis;white-space:nowrap;}
.ajcrm-lightbox-close{width:38px;height:38px;display:inline-flex;align-items:center;justify-content:center;border:0;border-radius:12px;background:#f1f5f9;color:#0f172a;font-size:26px;line-height:1;cursor:pointer;}
.ajcrm-lightbox-close:hover{background:#e2e8f0;}
.ajcrm-lightbox-body{flex:1;min-height:0;display:flex;align-items:center;justify-content:center;background:#0f172a;overflow:auto;}
.ajcrm-lightbox-image{display:block;max-width:100%;max-height:100%;object-fit:contain;}
.ajcrm-lightbox-frame{width:100%;height:100%;border:0;background:#fff;}
html.ajcrm-lightbox-open{overflow:hidden;}

@media (max-width:980px){
    .ajcrm-espace{padding:14px;background:#f8fafc;}
    .ajcrm-app-shell{display:block;max-width:100%;}
    .ajcrm-sidebar{position:relative;top:auto;min-height:0;margin-bottom:14px;padding:14px;border-radius:24px;}
    .ajcrm-sidebar .ajcrm-back-site,.ajcrm-sidebar-footer{display:none;}
    .ajcrm-sidebar-profile{margin:0 0 14px;padding:12px;}
    .ajcrm-sidebar-tabs{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:8px;}
    .ajcrm-sidebar-tabs .ajcrm-tab{display:flex;justify-content:center;padding:11px 8px;border-radius:14px;text-align:center;}
    .ajcrm-sidebar-tabs .ajcrm-tab-icon{display:none;}
    .ajcrm-tab-label{font-size:13px;}
    .ajcrm-main-panel{padding:18px;border-radius:24px;}
    .ajcrm-mobile-topbar{display:flex;align-items:center;justify-content:space-between;gap:10px;margin-bottom:18px;}
}
@media (max-width:560px){
    .ajcrm-espace{padding:10px;}
    .ajcrm-sidebar-profile .ajcrm-ec-avatar,.ajcrm-sidebar-profile .ajcrm-ec-avatar img,.ajcrm-sidebar-profile .ajcrm-avatar-init{width:46px;height:46px;}
    .ajcrm-sidebar-tabs{grid-template-columns:1fr;}
    .ajcrm-sidebar-tabs .ajcrm-tab{justify-content:flex-start;}
    .ajcrm-sidebar-tabs .ajcrm-tab-icon{display:inline-flex;}
    .ajcrm-mobile-topbar{align-items:stretch;flex-direction:column;}
    .ajcrm-mobile-topbar .ajcrm-btn,.ajcrm-mobile-topbar .ajcrm-back-site{width:100%;justify-content:center;box-sizing:border-box;}
    .ajcrm-main-panel{padding:14px;border-radius:20px;}
    .ajcrm-lightbox{padding:10px;}
    .ajcrm-lightbox-dialog{height:86vh;border-radius:18px;}
    .ajcrm-lightbox-header,.ajcrm-lightbox-footer{padding:11px;}
}

/* v2.0.8 – Liste synthétique + détail projet */
.ajcrm-projects-overview-compact{
    margin-bottom:22px;
}
.ajcrm-project-list-modern{
    display:grid;
    gap:14px;
}
.ajcrm-project-row-card{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto auto;
    align-items:center;
    gap:16px;
    position:relative;
    padding:18px;
    border:1px solid #e5e7eb;
    border-left:4px solid var(--projet-color,#2271b1);
    border-radius:18px;
    background:#fff;
    box-shadow:0 14px 34px rgba(15,23,42,.055);
    transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}
.ajcrm-project-row-card:hover{
    transform:translateY(-2px);
    border-color:#dbe4ee;
    box-shadow:0 18px 46px rgba(15,23,42,.09);
}
.ajcrm-project-row-main{
    display:flex;
    align-items:flex-start;
    min-width:0;
    gap:14px;
    color:inherit;
    text-decoration:none;
}
.ajcrm-project-row-icon{
    width:42px;
    height:42px;
    flex:0 0 42px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    border-radius:14px;
    background:#f8fafc;
    box-shadow:inset 0 0 0 1px #e2e8f0;
    font-size:20px;
}
.ajcrm-project-row-content{
    min-width:0;
    display:flex;
    flex-direction:column;
    gap:5px;
}
.ajcrm-project-row-title{
    color:#0f172a;
    font-size:17px;
    font-weight:900;
    line-height:1.25;
}
.ajcrm-project-row-desc{
    color:#64748b;
    font-size:13px;
    line-height:1.5;
}
.ajcrm-project-row-meta{
    display:flex;
    flex-wrap:wrap;
    justify-content:flex-end;
    align-items:center;
    gap:8px;
}
.ajcrm-project-row-pill{
    display:inline-flex;
    align-items:center;
    gap:5px;
    min-height:28px;
    padding:5px 9px;
    border:1px solid #e2e8f0;
    border-radius:999px;
    background:#f8fafc;
    color:#475569;
    font-size:12px;
    font-weight:800;
    white-space:nowrap;
}
.ajcrm-project-row-action{
    white-space:nowrap;
}
.ajcrm-project-detail-page{
    display:grid;
    gap:18px;
}
.ajcrm-project-detail-topbar{
    display:flex;
    align-items:center;
    justify-content:space-between;
}
.ajcrm-project-back{
    width:max-content;
}
.ajcrm-project-detail-hero{
    display:grid;
    grid-template-columns:minmax(0,1fr) auto;
    gap:18px;
    align-items:start;
    padding:24px;
    border:1px solid #e2e8f0;
    border-top:4px solid var(--projet-color,#2271b1);
    border-radius:22px;
    background:linear-gradient(180deg,#fff,#f8fafc);
    box-shadow:0 16px 42px rgba(15,23,42,.06);
}
.ajcrm-project-detail-hero h2{
    margin:4px 0 10px;
    color:#0f172a;
    font-size:clamp(24px,3vw,34px);
    line-height:1.1;
    letter-spacing:-.035em;
}
.ajcrm-project-detail-desc,
.ajcrm-project-detail-desc-muted{
    color:#475569;
    font-size:15px;
    line-height:1.7;
}
.ajcrm-project-detail-desc p{
    margin:0 0 10px;
}
.ajcrm-project-detail-desc p:last-child{
    margin-bottom:0;
}
.ajcrm-project-detail-status{
    display:flex;
    flex-direction:column;
    align-items:flex-end;
    gap:8px;
}
.ajcrm-project-detail-grid{
    display:grid;
    grid-template-columns:repeat(4,minmax(0,1fr));
    gap:12px;
}
.ajcrm-project-detail-files{
    display:grid;
    gap:16px;
}
.ajcrm-project-detail-files .ajcrm-files-section{
    padding:18px;
    border:1px solid #e2e8f0;
    border-radius:20px;
    background:#fff;
    box-shadow:0 12px 34px rgba(15,23,42,.045);
}
@media (max-width:1180px){
    .ajcrm-project-row-card{
        grid-template-columns:minmax(0,1fr);
        align-items:start;
    }
    .ajcrm-project-row-meta{
        justify-content:flex-start;
    }
    .ajcrm-project-row-action{
        width:max-content;
    }
    .ajcrm-project-detail-grid{
        grid-template-columns:repeat(2,minmax(0,1fr));
    }
}
@media (max-width:680px){
    .ajcrm-project-row-card{
        padding:14px;
        border-radius:16px;
    }
    .ajcrm-project-row-main{
        gap:10px;
    }
    .ajcrm-project-row-icon{
        width:36px;
        height:36px;
        flex-basis:36px;
        border-radius:12px;
    }
    .ajcrm-project-row-action,
    .ajcrm-project-back{
        width:100%;
        justify-content:center;
    }
    .ajcrm-project-detail-hero{
        grid-template-columns:1fr;
        padding:18px;
        border-radius:18px;
    }
    .ajcrm-project-detail-status{
        align-items:flex-start;
    }
    .ajcrm-project-detail-grid{
        grid-template-columns:1fr;
    }
}

/* Hélios CRM v2.0.9 – Interface client plus professionnelle */
.ajcrm-espace{
    --ajcrm-primary:#1f6feb;
    --ajcrm-primary-dark:#1554b7;
    --ajcrm-text:#111827;
    --ajcrm-muted:#6b7280;
    --ajcrm-border:#e5e7eb;
    --ajcrm-soft:#f8fafc;
    --ajcrm-radius:10px;
    color:var(--ajcrm-text);
}
.ajcrm-app-shell{
    width:100%;
    max-width:100% !important;
    margin:0;
    gap:20px;
}
.ajcrm-sidebar,
.ajcrm-main-panel,
.ajcrm-login-card,
.ajcrm-projects-overview,
.ajcrm-project-row-card,
.ajcrm-project-detail-hero,
.ajcrm-projet-meta-item,
.ajcrm-files-section,
.ajcrm-profil-card,
.ajcrm-chat-wrap,
.ajcrm-profile-avatar,
.ajcrm-lightbox-dialog,
.ajcrm-client-upload-zone{
    border-radius:var(--ajcrm-radius) !important;
}
.ajcrm-sidebar{
    border:1px solid var(--ajcrm-border);
    box-shadow:none;
    background:#fff;
}
.ajcrm-main-panel{
    border:1px solid var(--ajcrm-border);
    box-shadow:none;
    background:#fff;
}
.ajcrm-sidebar-profile{
    border-radius:8px;
    background:var(--ajcrm-soft);
    border:1px solid var(--ajcrm-border);
}
.ajcrm-sidebar-hello,
.ajcrm-eyebrow{
    color:var(--ajcrm-muted);
    font-weight:600;
    letter-spacing:.04em;
}
.ajcrm-sidebar-profile-text strong,
.ajcrm-project-row-title,
.ajcrm-files-title,
.ajcrm-profil-card h3{
    font-weight:500 !important;
    color:var(--ajcrm-text);
}
.ajcrm-sidebar-profile-text small,
.ajcrm-project-row-desc,
.ajcrm-projects-overview p,
.ajcrm-project-detail-desc,
.ajcrm-project-detail-desc-muted,
.ajcrm-files-empty-text{
    color:var(--ajcrm-muted);
}
.ajcrm-sidebar-tabs{
    border:0;
    gap:4px;
}
.ajcrm-sidebar-tabs .ajcrm-tab{
    border-radius:8px;
    padding:10px 12px;
    color:#374151;
    font-weight:500;
    border:1px solid transparent;
}
.ajcrm-sidebar-tabs .ajcrm-tab:hover{
    background:#f3f6fb;
    color:var(--ajcrm-text);
}
.ajcrm-sidebar-tabs .ajcrm-tab-active{
    background:#eef5ff;
    border-color:#cfe1ff;
    color:#0f4da2;
    box-shadow:none;
}
.ajcrm-btn{
    border-radius:8px;
    font-weight:500;
    box-shadow:none !important;
}
.ajcrm-btn-primary{
    background:var(--ajcrm-primary);
}
.ajcrm-btn-primary:hover{
    background:var(--ajcrm-primary-dark);
}
.ajcrm-btn-outline{
    border:1px solid #cbd5e1;
    color:#334155;
    background:#fff;
}
.ajcrm-btn-outline:hover{
    border-color:#94a3b8;
    background:#f8fafc;
    color:#111827;
}
.ajcrm-back-site,
.ajcrm-login-back-site{
    display:inline-flex;
    align-items:center;
    color:#475569;
    text-decoration:none;
    font-size:13px;
    font-weight:500;
}
.ajcrm-back-site:hover,
.ajcrm-login-back-site:hover{
    color:var(--ajcrm-primary);
    text-decoration:none;
}
.ajcrm-login-back-site{
    justify-content:center;
    margin-top:16px;
    width:100%;
}
.ajcrm-login-mark{
    width:42px;
    height:42px;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    margin:0 auto 18px;
    border-radius:10px;
    background:#111827;
    color:#fff;
    font-size:18px;
    font-weight:600;
}
.ajcrm-login-card h2,
.ajcrm-projects-overview h2,
.ajcrm-project-detail-hero h2,
.ajcrm-empty-state h2{
    font-weight:500 !important;
    letter-spacing:-.02em;
    color:var(--ajcrm-text);
}
.ajcrm-projects-overview{
    padding:22px;
    border-color:var(--ajcrm-border);
    background:#fff;
    box-shadow:none;
}
.ajcrm-projects-stats span,
.ajcrm-project-row-pill,
.ajcrm-projet-ref{
    border-radius:999px;
    background:#f8fafc;
    border:1px solid var(--ajcrm-border);
    color:#475569;
    font-weight:500;
}
.ajcrm-project-row-card{
    grid-template-columns:minmax(0,1fr) minmax(220px,auto) auto;
    padding:16px 18px;
    border:1px solid var(--ajcrm-border);
    border-left:3px solid var(--projet-color,var(--ajcrm-primary));
    box-shadow:none;
}
.ajcrm-project-row-card:hover{
    transform:none;
    border-color:#cbd5e1;
    box-shadow:0 10px 24px rgba(15,23,42,.06);
}
.ajcrm-project-row-main{
    gap:0;
}
.ajcrm-status-badge,
.ajcrm-badge{
    border-radius:999px !important;
    padding:4px 9px !important;
    font-size:11px !important;
    line-height:1.2;
    font-weight:500 !important;
    letter-spacing:.01em;
}
.ajcrm-project-detail-hero,
.ajcrm-projet-meta-item,
.ajcrm-files-section,
.ajcrm-profil-card{
    border-color:var(--ajcrm-border);
    box-shadow:none;
    background:#fff;
}
.ajcrm-projet-meta-item strong,
.ajcrm-dl-row dt{
    font-weight:500 !important;
}
.ajcrm-meta-label{
    color:var(--ajcrm-muted);
    font-weight:500;
}
.ajcrm-chip-icon{
    min-width:40px;
    height:32px;
    border-radius:7px;
    background:#f1f5f9;
    color:#334155;
    font-size:11px;
    font-weight:600;
    letter-spacing:.03em;
}
.ajcrm-file-chip-modern{
    border-radius:8px !important;
    box-shadow:none;
}
.ajcrm-client-upload-icon{
    width:34px;
    height:34px;
    border-radius:8px;
    background:#eef5ff;
    color:var(--ajcrm-primary);
    display:inline-flex;
    align-items:center;
    justify-content:center;
    font-size:24px;
    line-height:1;
    font-weight:300;
}
.ajcrm-chat-bubble{
    border-radius:10px;
    font-size:14px;
}
.ajcrm-bubble-admin{
    background:#f3f4f6;
    color:#111827;
}
.ajcrm-bubble-client{
    background:#1f2937;
}
.ajcrm-mobile-menu{display:none;}

@media (max-width:980px){
    .ajcrm-espace{padding:0;background:#f8fafc;}
    .ajcrm-app-shell{display:block;}
    .ajcrm-sidebar{display:none;}
    .ajcrm-main-panel{
        border-radius:0 !important;
        min-height:100vh;
        border:0;
        padding:16px;
    }
    .ajcrm-mobile-topbar{display:none !important;}
    .ajcrm-mobile-menu{
        position:relative;
        display:block;
        margin:0 0 16px;
        z-index:30;
    }
    .ajcrm-mobile-menu-toggle{
        width:100%;
        min-height:46px;
        display:flex;
        align-items:center;
        justify-content:space-between;
        gap:10px;
        padding:10px 12px;
        border:1px solid var(--ajcrm-border);
        border-radius:10px;
        background:#fff;
        color:#111827;
        font:inherit;
        font-weight:500;
        cursor:pointer;
    }
    .ajcrm-mobile-menu-chevron{
        margin-left:auto;
        color:#64748b;
        transition:transform .15s ease;
    }
    .ajcrm-mobile-menu.is-open .ajcrm-mobile-menu-chevron{
        transform:rotate(180deg);
    }
    .ajcrm-mobile-menu-panel{
        display:none;
        position:absolute;
        top:calc(100% + 8px);
        left:0;
        right:0;
        padding:6px;
        border:1px solid var(--ajcrm-border);
        border-radius:10px;
        background:#fff;
        box-shadow:0 18px 40px rgba(15,23,42,.14);
    }
    .ajcrm-mobile-menu.is-open .ajcrm-mobile-menu-panel{display:block;}
    .ajcrm-mobile-menu-panel a{
        display:flex;
        align-items:center;
        justify-content:space-between;
        gap:10px;
        padding:11px 12px;
        border-radius:8px;
        color:#374151;
        text-decoration:none;
        font-size:14px;
        font-weight:500;
    }
    .ajcrm-mobile-menu-panel a:hover,
    .ajcrm-mobile-menu-panel a.is-active{
        background:#f3f6fb;
        color:#111827;
    }
    .ajcrm-project-row-card{
        grid-template-columns:1fr;
        gap:12px;
    }
    .ajcrm-project-row-meta{
        justify-content:flex-start;
    }
    .ajcrm-project-row-action{
        width:100%;
        justify-content:center;
        box-sizing:border-box;
    }
    .ajcrm-projects-overview{
        flex-direction:column;
        align-items:flex-start;
        padding:18px;
    }
}
@media (max-width:560px){
    .ajcrm-main-panel{padding:12px;}
    .ajcrm-projects-overview h2,
    .ajcrm-project-detail-hero h2{font-size:1.35rem;}
    .ajcrm-project-detail-grid{grid-template-columns:1fr;}
}
.ajcrm-file-chip-modern.ajcrm-file-preview{
    display:flex;
	flex-wrap: wrap;
    align-items:center;
    margin-top:0;
    background:#fff;
    border:1px solid var(--ajcrm-border);
    padding:12px;
}


/* Hélios CRM v2.0.10 – logo connexion + compte non lié */
.ajcrm-login-mark{
    overflow:hidden;
    background:#fff;
    border:1px solid var(--ajcrm-border);
    box-shadow:0 1px 2px rgba(15,23,42,.06);
}
.ajcrm-login-mark img{
    max-width:80%;
    max-height:80%;
    width:auto;
    height:auto;
    object-fit:contain;
    display:block;
}
.ajcrm-login-mark span{
    display:inline-flex;
    align-items:center;
    justify-content:center;
    width:100%;
    height:100%;
    background:#111827;
    color:#fff;
}
.ajcrm-client-link-notice{
    max-width:680px;
    margin:40px auto;
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:16px;
}
.ajcrm-client-link-notice p{
    margin:0;
}
@media (max-width:640px){
    .ajcrm-client-link-notice{
        align-items:flex-start;
        flex-direction:column;
    }
}

/* Hélios CRM v2.0.11 – finitions identité client, mobile et badges colorés */
.ajcrm-login-mark{
    width:74px !important;
    height:74px !important;
    padding:10px !important;
    border-radius:18px !important;
    background:#fff !important;
}
.ajcrm-login-mark img{
    max-width:100% !important;
    max-height:100% !important;
    object-fit:contain !important;
}
.ajcrm-sidebar-profile-text strong{
    font-size:15px !important;
    font-weight:500 !important;
    line-height:1.25 !important;
}
.ajcrm-sidebar-profile-text small{
    margin-top:1px !important;
    font-size:12.5px !important;
    line-height:1.25 !important;
}
.ajcrm-mobile-client-header{display:none;}
.ajcrm-mobile-menu-chevron{
    width:18px !important;
    height:18px !important;
    display:inline-flex !important;
    align-items:center !important;
    justify-content:center !important;
    color:#64748b !important;
    transform-origin:center !important;
}
.ajcrm-mobile-menu-chevron svg{
    width:12px;
    height:12px;
    fill:currentColor;
    display:block;
}
.ajcrm-status-badge[style],
.ajcrm-badge[style]{
    box-shadow:none !important;
    border-width:1px !important;
}
@media (max-width:980px){
    .ajcrm-mobile-client-header{
        display:block;
        margin:0 0 12px;
    }
    .ajcrm-mobile-profile{
        display:flex !important;
        align-items:center !important;
        gap:12px !important;
        margin:0 !important;
        padding:12px !important;
        background:#fff !important;
        border:1px solid var(--ajcrm-border) !important;
        border-radius:10px !important;
    }
    .ajcrm-mobile-profile .ajcrm-ec-avatar,
    .ajcrm-mobile-profile .ajcrm-ec-avatar img,
    .ajcrm-mobile-profile .ajcrm-avatar-init{
        width:44px !important;
        height:44px !important;
    }
    .ajcrm-mobile-menu-toggle{
        border-radius:10px !important;
        font-weight:500 !important;
    }
}

/* ── Connexion Google ──────────────────────────────────────────────── */
.ajcrm-google-login-btn{display:flex;align-items:center;justify-content:center;gap:10px;width:100%;margin:14px 0 0;padding:12px 14px;border:1px solid #d1d5db;border-radius:8px;background:#fff;color:#111827;text-decoration:none;font-weight:500;transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease}.ajcrm-google-login-btn:hover{border-color:#9ca3af;box-shadow:0 8px 20px rgba(15,23,42,.08);transform:translateY(-1px);color:#111827}.ajcrm-google-g{display:inline-flex;align-items:center;justify-content:center;width:22px;height:22px;border-radius:50%;border:1px solid #e5e7eb;font-weight:700;font-family:Arial,sans-serif;color:#4285f4;background:#fff}.login .ajcrm-google-login-btn{max-width:320px;margin:14px auto}.login .ajcrm-google-g{line-height:1}

/* Hélios CRM v2.0.15 – Ajustements sidebar / identité espace client */
.ajcrm-sidebar-header{
    display:flex;
    flex-direction:column;
    gap:14px;
    padding:0 0 16px;
    margin:0 0 14px;
    border-bottom:1px solid var(--ajcrm-border,#e5e7eb);
}
.ajcrm-sidebar-brand,
.ajcrm-mobile-brand-header{
    display:flex;
    align-items:center;
    gap:10px;
    min-width:0;
}
.ajcrm-sidebar-brand-logo{
    width:38px;
    height:38px;
    display:inline-flex;
    flex:0 0 38px;
    align-items:center;
    justify-content:center;
    overflow:hidden;
    border:1px solid #edf2f7;
    border-radius:10px;
    background:#fff;
    color:var(--ajcrm-primary,#1f6feb);
    font-size:16px;
    font-weight:700;
}
.ajcrm-sidebar-brand-logo img{
    display:block;
    max-width:82%;
    max-height:82%;
    width:auto;
    height:auto;
    object-fit:contain;
}
.ajcrm-sidebar-brand-text{
    color:#111827;
    font-size:15px;
    font-weight:600;
    line-height:1.25;
}
.ajcrm-sidebar-header .ajcrm-sidebar-return{
    width:100%;
    justify-content:center;
    min-height:38px;
    padding:9px 11px;
}
.ajcrm-sidebar-footer{
    display:flex;
    flex-direction:column;
    gap:10px;
    padding-top:14px !important;
    margin-top:auto;
    border-top:1px solid var(--ajcrm-border,#e5e7eb);
}
.ajcrm-sidebar-footer .ajcrm-sidebar-profile{
    margin:0 !important;
    padding:9px !important;
    gap:9px !important;
    border-radius:8px !important;
}
.ajcrm-sidebar-footer .ajcrm-sidebar-profile .ajcrm-ec-avatar,
.ajcrm-sidebar-footer .ajcrm-sidebar-profile .ajcrm-ec-avatar img,
.ajcrm-sidebar-footer .ajcrm-sidebar-profile .ajcrm-avatar-init{
    width:38px !important;
    height:38px !important;
    font-size:14px !important;
}
.ajcrm-sidebar-footer .ajcrm-sidebar-profile-text strong{
    font-size:13.5px !important;
}
.ajcrm-sidebar-footer .ajcrm-sidebar-profile-text small{
    font-size:12px !important;
}
.ajcrm-sidebar-logout{
    min-height:38px;
}
@media (max-width:980px){
    .ajcrm-mobile-client-header{
        display:block;
        margin:0 0 12px;
        padding:12px;
        border:1px solid var(--ajcrm-border,#e5e7eb);
        border-radius:10px;
        background:#fff;
    }
    .ajcrm-mobile-brand-header .ajcrm-sidebar-brand-logo{
        width:34px;
        height:34px;
        flex-basis:34px;
    }
    .ajcrm-mobile-brand-header .ajcrm-sidebar-brand-text{
        font-size:15px;
    }
}

/* Hélios CRM v2.0.17 - écrans mot de passe front-end */
.ajcrm-password-card .ajcrm-login-form { margin-top: 22px; }
.ajcrm-password-card .ajcrm-login-back-site { margin-top: 16px; }
.ajcrm-password-card .ajcrm-btn + .ajcrm-login-back-site { display: inline-flex; }
