/* Onglet Agenda : grille horaire sur 3 jours (1 jour sur téléphone) */
.ag-connect { max-width: 620px; display: flex; flex-direction: column; gap: 10px; }
.ag-connect .btn { width: fit-content; }
.ag-wrap { display: grid; grid-template-columns: 44px minmax(0, 1fr); gap: 8px; }
.ag-cols { display: grid; gap: 10px; }
.ag-col { min-width: 0; display: flex; flex-direction: column; gap: 6px; }
.ag-colhead { font-weight: 700; font-size: 0.9rem; text-transform: capitalize; height: 22px; }
.ag-colhead.is-today { color: var(--accent); }
.ag-band { min-height: 30px; display: flex; flex-direction: column; gap: 4px; }
.ag-hours .ag-band { min-height: 30px; }
.ag-task, .ag-allday { text-align: left; border: 1px solid var(--line); background: var(--panel); color: var(--ink); border-radius: 8px; padding: 4px 8px; font-size: 0.8rem; cursor: pointer; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.ag-task.is-relance { border-color: var(--warn); color: var(--warn); background: var(--warn-soft); }
.ag-allday { background: var(--accent-soft); border-color: transparent; color: var(--accent); font-weight: 600; }
.ag-grid, .ag-hgrid { position: relative; }
.ag-grid { background: var(--panel); border: 1px solid var(--line); border-radius: 10px; cursor: copy; overflow: hidden; }
.ag-slot { position: absolute; left: 0; right: 0; border-top: 1px solid var(--line); height: 48px; pointer-events: none; }
.ag-slot::after { content: ""; position: absolute; left: 0; right: 0; top: 24px; border-top: 1px dashed var(--bg-soft); }
.ag-hgrid span { position: absolute; right: 0; transform: translateY(-6px); font-size: 0.72rem; color: var(--ink-3); }
.ag-now { position: absolute; left: 0; right: 0; border-top: 2px solid var(--bad); z-index: 2; pointer-events: none; }
.ag-ev { position: absolute; z-index: 1; display: flex; flex-direction: column; align-items: flex-start; gap: 1px; text-align: left; overflow: hidden; border: 0; border-left: 3px solid var(--ink-3); background: var(--bg-soft); color: var(--ink); border-radius: 6px; padding: 3px 6px; font-size: 0.75rem; cursor: pointer; }
.ag-ev b { font-weight: 700; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
.ag-ev span { color: var(--ink-3); font-size: 0.7rem; }
.ag-ev.is-mine { background: var(--accent-soft); border-left-color: var(--accent); }
.ag-ev:hover { filter: brightness(0.97); outline: 1px solid var(--ink-3); }
.ag-help { font-size: 0.8rem; }
.ag-times > div { display: flex; gap: 8px; align-items: center; }
.ag-mates { display: flex; flex-wrap: wrap; gap: 12px; }
.ag-mates label, .ag-check { display: inline-flex; gap: 6px; align-items: center; font-weight: 500; }
.ag-desc { background: var(--bg-soft); border-radius: 8px; padding: 10px; font-size: 0.85rem; }
.ag-ev.is-short { flex-direction: row; align-items: center; gap: 6px; padding: 1px 6px; }
.ag-ev.is-short span { order: -1; flex: none; }
.ag-hours { display: flex; flex-direction: column; gap: 6px; }
.ag-hgrid span:first-child { transform: none; }

/* Tâches dans l'agenda : mêmes cartes que l'onglet Tâches, couleur selon la priorité */
.ag-band .task { padding: 6px 8px; gap: 8px; border-radius: 9px; }
.ag-band .task-check { width: 16px; height: 16px; margin-top: 1px; }
.ag-band .task.prio-haute { background: var(--bad-soft); }
.ag-band .task.prio-normale { background: var(--accent-soft); }
.ag-band .task.prio-basse { background: var(--panel); }
.ag-band .task[data-task^="r-"] { background: var(--warn-soft); border-left-color: var(--warn); }
.ag-band .task-title { font-size: 0.82rem; }
.ag-legend { display: flex; flex-wrap: wrap; gap: 14px; font-size: 0.78rem; color: var(--ink-2); }
.ag-legend i { display: inline-block; width: 10px; height: 10px; border-radius: 3px; margin-right: 5px; vertical-align: -1px; }
