/* ==========================================================================
   Kit Heures (vh-*) — journées d'heures en frise, commun à tout le site.
   Chargé partout par templates/dxsite/base_standard.html, juste après dx-kit.css.

   Avant le 2026-11-10, ces règles vivaient dans project_module/css/hours_days.css (chargée
   aussi par DxResources) et la bande de chiffres du mois, la largeur des colonnes et la
   légende étaient recopiées dans team_member_detail.css, resources.css et
   dx-hours-grid.css : une retouche faite sur une fiche ne passait pas sur l'autre.

   Composants (balises dans dxsite/templatetags/dx_kit.py, HTML dans templates/shared/dx/hours/,
   démonstration sur /fr/home/administration/ui-kit/, section « Heures ») :
     .vh-root            porte les variables ; posée sur le conteneur de la frise
     .vh-fiche           variante « mois d'une personne » : à fleur de carte, compacte
     .vh-fiche-head      en-tête de carte du mois (sélecteur, chiffres, actions)
     .vh-month-sum       chiffres du mois, encart teinté du module
     .vh-table           tableau des journées : .vh-week (bande de semaine), .vh-date,
                         .vh-col-tl > .vh-tl > .vh-seg (frise 5 h → 23 h), .vh-times > .vh-plage,
                         .vh-h (durées), .vh-grp (origines / statuts), .vh-act (actions,
                         boutons .vh-ib-sq)
     .vh-legend          légende des barres ; .vh-statuts : frise des statuts (status_tags)
   Balises : {% dx_hours_month %} (tableau du mois), {% dx_hours_legend %}, {% dx_hours_closed %}.
   Le tableau construit en JS des pages DxProject (project_module/js/hours_days.js) produit
   le même balisage par static/js/dx_hours.js (DxHours.*) ; ses colonnes propres, boutons,
   fenêtres et la modale de correction restent dans hours_days.css. Les applications mobiles (kit « application » à venir) reprendront ce
   fichier plutôt que leurs copies.
   ========================================================================== */

/* Bootstrap Icons dans le contenu injecté par JS */
.vh-root [class*=" bi-"]::before,
#editModal [class*=" bi-"]::before {
  display: inline-block;
  font-family: bootstrap-icons !important;
  font-style: normal;
  font-weight: normal !important;
  line-height: 1;
  vertical-align: -.125em;
}

/* Couleurs des barres (chantier, atelier, bureau, trajet) : à la racine, pour toute frise d'heures
   du site, y compris la grille du mois de l'atelier (.whm-seg, dx-hours-grid.css) */
:root {
  --vh-seg-chantier: #f97316;
  --vh-seg-atelier: #3b82f6;
  /* Heures de bureau (DxResources › Mes heures, 2026-11-19) */
  --vh-seg-bureau: #8b5cf6;
  --vh-seg-transport: #94a3b8;
}

/* Variables. La fenêtre de correction (#editModal) et une légende posée seule sont hors de
   .vh-root : mêmes variables. --vh-accent : couleur du module (posée par
   partials/_heures_edit_modal.html), orange DxProject par défaut. */
.vh-root, .vh-legend, .vh-tip, #editModal {
  --vh-accent: #ffae0a;
  --vh-accent-soft: color-mix(in srgb, var(--vh-accent) 16%, var(--dk-tint-base, #fff));
  --vh-line: var(--dk-border, #e5e7eb);
  --vh-line-2: var(--dk-border, #f1f2f4);
  /* Trait entre deux jours : nettement plus marqué que les lignes d'une même journée */
  --vh-day-sep: color-mix(in srgb, var(--vh-ink-3) 45%, transparent);
  --vh-ink: var(--dk-text, #1f2937);
  --vh-ink-2: var(--dk-text-muted, #4b5563);
  --vh-ink-3: var(--dk-text-faint, #5f6b7d);
  --vh-week-bg: color-mix(in srgb, #fef3c7 var(--dk-pastel, 100%), #4d4219);
  --vh-week-ink: color-mix(in srgb, #92400e var(--dk-lift, 100%), #fba67d);
}

/* Légende des barres */
.vh-legend { display: flex; gap: 14px; flex-wrap: wrap; font-size: .78rem; color: var(--vh-ink-2); margin-top: .5rem; }
.vh-legend span { display: inline-flex; align-items: center; gap: 6px; }
.vh-sw { width: 18px; height: 8px; border-radius: 2px; display: inline-block; }
.vh-sw.chantier { background: var(--vh-seg-chantier); }
.vh-sw.atelier { background: var(--vh-seg-atelier); }
.vh-sw.bureau { background: var(--vh-seg-bureau); }
.vh-sw.transport { background: repeating-linear-gradient(135deg, var(--vh-seg-transport) 0 3px, var(--dk-surface-3, #cbd5e1) 3px 6px); }
.vh-sw.pause { border: 1px dashed var(--vh-ink-3); }
.vh-sw.ctx { background: var(--vh-seg-atelier); opacity: .28; }

/* Blocs (projet, atelier ou personne) */
.vh-bloc { border: 1px solid var(--vh-line); border-radius: 8px; overflow: clip; background: var(--dk-surface, white); box-shadow: 0 1px 2px rgba(0,0,0,.06); }
.vh-bloc + .vh-bloc { margin-top: 14px; }

/* Tableau des journées. Jamais de défilement horizontal : il tient dans la largeur, les
   colonnes se resserrent */
.vh-table-wrap { overflow-x: clip; container-type: inline-size; }
.vh-table { width: 100%; border-collapse: collapse; }
.vh-table thead th {
  background: var(--dk-surface-2, #f3f4f6); color: var(--dk-text-muted, #566173); font-size: .68rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .05em; text-align: left; padding: .4rem .55rem; border-bottom: 1px solid var(--vh-line); white-space: nowrap;
  position: sticky; top: var(--app-header-h, 48px); z-index: 3;
}
/* En-tête collant : sous la barre du site quand la page défile, en haut du cadre quand
   c'est lui qui défile (.dx-scroll) */
.dx-scroll .vh-table thead th { top: 0; }
.vh-table .r { text-align: right; }
.vh-table .c { text-align: center; }
.vh-table tbody td { padding: .38rem .55rem; border-bottom: 1px solid var(--vh-line-2); vertical-align: middle; font-size: .85rem; }
.vh-table tr.day-start td { border-top: 2px solid var(--vh-day-sep); }
.vh-table tbody tr.day-start:first-child td, .vh-table tr.vh-week + tr.day-start td { border-top-color: var(--vh-line); border-top-width: 1px; }
.vh-table tbody tr:not(.vh-week):hover td:not(.vh-date) { background: var(--dk-surface-2, #fafafa); }
.vh-date { color: var(--vh-ink-2); white-space: nowrap; font-weight: 600; width: 88px; background: var(--dk-surface-2, #f8fafc); border-right: 1px solid var(--vh-line); }
.vh-date small { display: block; font-weight: 400; color: var(--vh-ink-3); font-size: .72rem; }

/* Bande de semaine, collée sous l'en-tête des colonnes tant qu'on est dans la semaine :
   la suivante vient la recouvrir. --vh-thead-h mesurée par hours_days.js */
.vh-week td { background: var(--vh-week-bg); color: var(--vh-week-ink); padding: .32rem .55rem; font-size: .82rem; border-top: 1px solid color-mix(in srgb, #fde68a var(--dk-tint-line, 100%), var(--dk-tint-base, #000)); border-bottom: 1px solid color-mix(in srgb, #fde68a var(--dk-tint-line, 100%), var(--dk-tint-base, #000)); }
.vh-table tr.vh-week td { position: sticky; top: calc(var(--app-header-h, 48px) + var(--vh-thead-h, 1.75rem)); z-index: 3; }
.dx-scroll .vh-table tr.vh-week td { top: calc(var(--vh-thead-h, 1.75rem) - 1px); }
.vh-week-row { display: flex; align-items: center; gap: 16px; flex-wrap: wrap;
  position: sticky; left: .55rem; width: calc(100cqw - 1.1rem); box-sizing: border-box; }
.vh-week-row .wk { font-weight: 700; }
.vh-week-row .tot { display: inline-flex; gap: 12px; color: color-mix(in srgb, #a16207 var(--dk-lift, 100%), #f2ae64); }
.vh-week-row .tot b { color: var(--vh-week-ink); }

/* Frise de la journée : 5 h → 23 h (resources_module/hours/frise_journees.py) */
.vh-tl { position: relative; height: 22px; min-width: 0; border-radius: 3px;
  background: repeating-linear-gradient(90deg, transparent 0 calc(100%/18 - 1px), var(--dk-surface-2, #eef0f3) calc(100%/18 - 1px) calc(100%/18)); }
.vh-seg { position: absolute; top: 3px; height: 16px; border-radius: 2px; }
.vh-seg.chantier { background: var(--vh-seg-chantier); }
.vh-seg.atelier { background: var(--vh-seg-atelier); }
.vh-seg.bureau { background: var(--vh-seg-bureau); }
.vh-seg.transport { background: repeating-linear-gradient(135deg, var(--vh-seg-transport) 0 3px, var(--dk-surface-3, #cbd5e1) 3px 6px); }
.vh-seg.pause { background: var(--dk-surface, #fff); border: 1px dashed var(--vh-ink-3); top: 4px; height: 14px; }
/* En cours : bout estompé de longueur fixe, la barre du jour s'allonge jusqu'à maintenant */
.vh-seg.open { -webkit-mask-image: linear-gradient(90deg, #000 max(40%, calc(100% - 28px)), transparent); mask-image: linear-gradient(90deg, #000 max(40%, calc(100% - 28px)), transparent); transition: width .6s ease; }
.vh-seg.ctx { opacity: .28; }
.vh-scale { position: relative; height: 12px; min-width: 0; font-size: .62rem; color: var(--vh-ink-3); text-transform: none; letter-spacing: 0; }
.vh-scale span { position: absolute; transform: translateX(-50%); }

/* Horaires et durées */
.vh-times { white-space: nowrap; color: var(--vh-ink-2); }
.vh-times .mono { font-family: ui-monospace, Consolas, monospace; font-size: .8rem; color: var(--vh-ink); }
.vh-plage { display: flex; align-items: center; gap: .35rem; }
.vh-plage .bi { font-size: .72rem; width: 12px; }
.vh-plage.chantier .bi { color: var(--vh-seg-chantier); }
.vh-plage.atelier .bi { color: var(--vh-seg-atelier); }
.vh-plage.bureau .bi { color: var(--vh-seg-bureau); }
.vh-plage.transport .bi { color: var(--dk-text-muted, #566173); }
.vh-plage.transport .mono { color: var(--vh-ink-2); }
.vh-plage-pause { display: inline-flex; align-items: center; gap: .2rem; margin-left: .15rem; font-size: .72rem; color: var(--vh-ink-3); white-space: nowrap; }
.vh-plage-pause .bi { color: var(--vh-ink-3); width: auto; font-size: .68rem; }
.vh-plage-pause .mono { color: var(--vh-ink-3); }
/* Bulle des horaires (2026-11-10) : la plage porte data-dx-info-pop, le détail (une ligne par
   morceau : icône, libellé, heures, durée ; pause ; total travaillé) est dans un <template>
   affiché par static/js/dx_info_pop.js, posé sur <body> : jamais coupé par le tableau */
.vh-plage[data-dx-info-pop] { cursor: help; border-radius: 4px; }
.vh-plage[data-dx-info-pop]:focus-visible { outline: 2px solid var(--vh-accent); outline-offset: 2px; }
.vh-tip { display: grid; grid-template-columns: 16px auto auto auto; column-gap: .55rem; row-gap: .3rem;
  align-items: center; min-width: 13rem; font-size: .8rem; color: var(--vh-ink); }
.vh-tip-head { grid-column: 1 / -1; font-size: .72rem; font-weight: 600; color: var(--vh-ink-2);
  padding-bottom: .35rem; margin-bottom: .1rem; border-bottom: 1px solid var(--vh-line); }
.vh-tip-row, .vh-tip-foot { display: contents; }
.vh-tip .bi { justify-self: center; font-size: .8rem; }
.vh-tip-row.chantier .bi { color: var(--vh-seg-chantier); }
.vh-tip-row.atelier .bi { color: var(--vh-seg-atelier); }
.vh-tip-row.bureau .bi { color: var(--vh-seg-bureau); }
.vh-tip-row.transport .bi { color: var(--vh-seg-transport); }
.vh-tip-lbl { font-weight: 600; }
.vh-tip .mono { font-family: ui-monospace, Consolas, monospace; font-size: .76rem; white-space: nowrap; }
.vh-tip-dur { justify-self: end; font-variant-numeric: tabular-nums; color: var(--vh-ink-2); white-space: nowrap; }
.vh-tip-row.pause > * { color: var(--vh-ink-3); font-weight: 400; font-size: .74rem; }
.vh-tip-row.pause .vh-tip-lbl { font-style: italic; }
.vh-tip-foot > * { padding-top: .35rem; border-top: 1px solid var(--vh-line); margin-top: .1rem; }
.vh-tip-foot .bi { color: var(--vh-ink-2); }
.vh-tip-foot .vh-tip-dur { font-weight: 700; color: var(--vh-ink); }
.vh-h { font-weight: 700; font-variant-numeric: tabular-nums; }
.vh-h.zero { color: var(--vh-ink-3); font-weight: 400; }
.vh-h.vh-ctx { color: var(--vh-ink-3); font-weight: 400; font-style: italic; }

/* Frise : environ un quart de la largeur, elle cède la place aux chiffres quand le
   cadre se resserre, puis disparaît (la colonne Horaires dit la même chose) */
.vh-table .vh-col-tl { width: 24%; }
@container (max-width: 1150px) {
  .vh-table .vh-col-tl { display: none; }
}
@container (max-width: 760px) {
  .vh-table thead th, .vh-table tbody td { padding-left: .35rem; padding-right: .35rem; }
}

/* ── Mois d'une personne (.vh-fiche) ─────────────────────────────────────────
   Fiche DxProject (onglet Heures), fiche DxResources (section Heures) et mois d'un
   opérateur à l'atelier (en-tête et chiffres) : en-tête de carte mois + chiffres à gauche,
   actions à droite ; tableau à fleur de carte, en-tête de colonnes et bandeau de semaine
   teinté du module, lignes compactes, légende en pied. */
.vh-fiche-head.dx-section-head { flex-wrap: wrap; justify-content: flex-start; gap: .6rem 1rem; padding-top: .4rem; padding-bottom: .4rem; }
.vh-fiche-body.dx-section-body { padding: 0; }
.vh-fiche-body > :not(.vh-root) { margin: var(--dx-card-y) var(--dx-card-x); }
.vh-fiche-body > .vh-root { margin-top: 0; }

/* Chiffres du mois : encart compact, distinct du tableau des journées (pas un tableau de liste) */
.vh-month-sum { width: auto; border-collapse: separate; border-spacing: 0; border: 1px solid var(--dx-border); border-radius: var(--dx-radius); background: linear-gradient(100deg, rgba(var(--module-primary-rgb, 100, 116, 139), .14) 0%, rgba(var(--module-secondary-rgb, var(--module-primary-rgb, 100, 116, 139)), .12) 100%); font-variant-numeric: tabular-nums; }
.vh-month-sum th { padding: .2rem .7rem 0; font-size: .62rem; line-height: 1.2; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--dk-text-muted, #64748b); white-space: nowrap; background: none; border: 0; }
.vh-month-sum td { padding: 0 .7rem .2rem; font-size: .88rem; line-height: 1.25; font-weight: 600; white-space: nowrap; border: 0; }
.vh-month-sum th + th, .vh-month-sum td + td { border-left: 1px solid var(--dx-border); }
.vh-month-sum .num { text-align: left; }
.vh-month-sum td.is-warn { color: color-mix(in srgb, #b45309 var(--dk-lift, 100%), #f6b26b); }
/* Totaux par origine (Chantier, Atelier, Bureau, 2026-11-21) : icône à la couleur de la barre ;
   celui d'une autre origine que celle de la page atténué (.vh-autre-origine) */
.vh-month-sum .vh-sum-ori .bi { margin-right: .25rem; font-size: .68rem; }
.vh-month-sum .vh-sum-ori.chantier .bi { color: var(--vh-seg-chantier); }
.vh-month-sum .vh-sum-ori.atelier .bi { color: var(--vh-seg-atelier); }
.vh-month-sum .vh-sum-ori.bureau .bi { color: var(--vh-seg-bureau); }
.vh-month-sum th.vh-autre-origine { font-weight: 500; cursor: help; }
.vh-month-sum th.vh-autre-origine .bi { filter: grayscale(1); opacity: .6; }
.vh-month-sum td.vh-autre-origine { font-weight: 500; color: var(--dk-text-muted, #64748b); }
@media (max-width: 767.98px) {
  .vh-month-sum { width: 100%; table-layout: fixed; }
  .vh-month-sum th { padding: .35rem .5rem 0; white-space: normal; }
  .vh-month-sum td { padding: .1rem .5rem .4rem; }
  .vh-month-sum td .dx-status { white-space: normal; }
}
/* Titre d'un tableau quand le mois en compte plusieurs (un par projet) */
.vh-fiche-titre { margin: 0; padding: .5rem var(--dx-card-x) .35rem; font-size: .85rem; font-weight: 600; }
.vh-fiche-titre a { color: inherit; text-decoration: none; }
.vh-fiche-titre a:hover { text-decoration: underline; }

.vh-fiche {
  --vh-week-bg: color-mix(in srgb, var(--module-primary, #1483eb) 8%, var(--dk-surface, #fff));
  --vh-week-ink: color-mix(in srgb, var(--module-primary, #1483eb) var(--dk-lift, 100%), var(--module-primary-lift, #e6e9ef));
}
.vh-fiche .vh-bloc { border: 0; border-radius: 0; box-shadow: none; }
.vh-fiche .vh-bloc + .vh-bloc { margin-top: 0; }
.vh-fiche .vh-table-wrap.dx-scroll { overflow-x: clip; overflow-y: auto; }
.vh-fiche .vh-table { font-size: .82rem; }
.vh-fiche .vh-mois { table-layout: fixed; }
.vh-fiche .vh-table thead th { height: 2rem; padding: 0 .6rem; background: var(--dk-surface-2, #f6f7f9);
  font-size: .66rem; letter-spacing: .04em; color: var(--vh-ink-3); }
.vh-fiche .vh-table tbody td { height: 2.15rem; padding: .25rem .6rem; font-size: .82rem; border-bottom: 1px solid var(--vh-line); }
.vh-fiche .vh-table tr.day-start td { border-top: 1px solid var(--vh-line); }
.vh-fiche .vh-table tbody tr:not(.vh-week):hover td:not(.vh-date) { background: var(--dk-surface-2, #f8fafc); }
/* Colonnes du mois d'une personne (.vh-mois, {% dx_hours_month %}) : Date, Frise, Horaires,
   Origine, Pause, Travail, Transport, Statut[, Actions]. La frise reste visible (le tableau a
   peu de colonnes) et ne disparaît qu'en très étroit. Le tableau d'équipe construit en JS
   (hours_days.js, 12 colonnes) prend l'apparence .vh-fiche mais garde ses colonnes. */
.vh-fiche .vh-mois .vh-col-tl { display: table-cell; width: 22%; }
.vh-fiche .vh-mois.has-act .vh-col-tl { width: 20%; }
.vh-fiche .vh-mois th:nth-child(1) { width: 6.5rem; }
.vh-fiche .vh-mois th:nth-child(3) { width: 10.5rem; }
.vh-fiche .vh-mois th:nth-child(5), .vh-fiche .vh-mois th:nth-child(6), .vh-fiche .vh-mois th:nth-child(7) { width: 5.5rem; }
.vh-fiche .vh-mois th:nth-child(8) { width: 8.5rem; }
/* « Non déclarée » (journée corrigée par le chef d'atelier) dépassait 7rem et était rognée :
   colonne élargie, et une pastille trop longue passe à la ligne plutôt que d'être coupée (2026-11-22) */
.vh-fiche .vh-mois td:nth-child(8) .dx-status { white-space: normal; max-width: 100%; }
.vh-fiche .vh-mois th:nth-child(9) { width: 6.5rem; }
.vh-fiche .vh-mois td:nth-child(4) { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Statut : plusieurs feuilles le même jour (une pastille par origine) passent l'une sous
   l'autre au lieu de déborder de la colonne (2026-11-13) */
.vh-fiche .vh-mois td:nth-child(8) .vh-grp { flex-wrap: wrap; row-gap: .2rem; padding: .1rem 0; }
.vh-fiche .vh-act { text-align: right; white-space: nowrap; }
.vh-fiche .vh-act .vh-grp { justify-content: flex-end; gap: .2rem; }
/* Bouton icône carré des actions d'une journée (Modifier, Valider, lien atelier) : même
   rendu dans la grille du mois de l'atelier (_hours_month_chef.html) */
.vh-ib-sq { display: inline-flex; align-items: center; justify-content: center; width: 1.6rem; height: 1.6rem; padding: 0;
  vertical-align: middle; border-radius: 6px; border: 1px solid var(--dk-border, #e2e8f0); background: var(--dk-surface, #fff);
  color: var(--dk-text-muted, #475569); font-size: .8rem; cursor: pointer; text-decoration: none; }
.vh-ib-sq:hover { border-color: rgba(var(--module-primary-rgb), .45); color: var(--module-primary); }
.vh-ib-sq.is-ok { border-color: #15803d; background: #15803d; color: #fff; }
.vh-ib-sq.is-ok:hover { background: #166534; border-color: #166534; color: #fff; }
.vh-ib-sq:disabled { opacity: .55; cursor: default; }
/* Pas de colonne d'actions collée à droite ici (le tableau tient dans sa carte),
   contrairement au rendu JS des pages DxProject (hours_days.css) */
.vh-fiche .vh-mois thead th:last-child { right: auto; box-shadow: none; }
/* Bandeau de semaine : semaine à la couleur du module, dates et total à la suite */
.vh-fiche .vh-week td { height: 2rem; padding: 0 .6rem; font-size: .78rem; color: var(--vh-ink-3);
  background: var(--vh-week-bg); border-top: 1px solid var(--vh-line); border-bottom: 1px solid var(--vh-line); }
.vh-fiche .vh-week-row { gap: .9rem; flex-wrap: nowrap; white-space: nowrap; }
.vh-fiche .vh-week-row .wk { font-size: .8rem; color: var(--vh-week-ink); }
.vh-fiche .vh-week-row .tot { gap: .9rem; color: var(--vh-ink-3); }
.vh-fiche .vh-week-row .tot b { color: var(--vh-ink); font-weight: 700; font-variant-numeric: tabular-nums; }
/* Frise : fine, un repère toutes les 3 h */
.vh-fiche .vh-tl { height: 12px;
  background: repeating-linear-gradient(90deg, transparent 0 calc(100%/6 - 1px), var(--vh-line) calc(100%/6 - 1px) calc(100%/6)); }
.vh-fiche .vh-tl:not(:has(.vh-seg)) { background: none; }
.vh-fiche .vh-seg, .vh-fiche .vh-seg.pause { top: 1px; height: 10px; }
.vh-fiche .vh-times .mono { font-size: .76rem; }
.vh-fiche .vh-date { font-size: .82rem; }
.vh-fiche .vh-legend { margin: 0; padding: .45rem var(--dx-card-x); border-top: 1px solid var(--vh-line); }
/* Aperçu des mois voisins (semaine coupée par le début ou la fin du mois) : grisé, comme les
   jours « hors » de la grille du chef d'atelier */
.vh-fiche .vh-table tr.is-hors > td { color: var(--vh-ink-3); }
.vh-fiche .vh-table tr.is-hors > td.vh-date { font-weight: 500; font-style: italic; }
.vh-fiche .vh-table tr.is-hors > td:not(.vh-date) > * { opacity: .5; }
.vh-fiche .vh-table tr.is-hors .vh-h { font-weight: 400; }
.vh-hors-label { font-size: .74rem; color: var(--vh-ink-3); }
/* Autre origine que celle de la page (contexte_heures(origine_hote=…), 2026-11-21) : DxProject
   valide le chantier, DxWarehouse l'atelier ; le reste du mois se lit grisé, sans action, avec son
   explication en infobulle. Une journée mixte n'est grisée que pour sa part étrangère : barre,
   texte d'origine, pastille ; la plage et les durées seulement si toute la ligne est étrangère. */
.vh-seg.vh-autre-origine { opacity: .3; }
.vh-plage.vh-autre-origine, .vh-plage.vh-autre-origine .mono { color: var(--vh-ink-3, #5f6b7d); }
.vh-plage.vh-autre-origine .bi { opacity: .5; }
.vh-grp-txt .vh-autre-origine { color: var(--vh-ink-3, #5f6b7d); font-style: italic; cursor: help; }
td.vh-h.vh-autre-origine { color: var(--vh-ink-3, #5f6b7d); font-weight: 400; }
.vh-grp > .vh-autre-origine { cursor: help; }
.vh-grp > .vh-autre-origine .dx-status { opacity: .55; filter: grayscale(1); }
/* Journée sur une ligne (2026-11-10) : origines, statuts et actions empilés par origine,
   une rangée de même hauteur dans chaque colonne pour qu'ils restent en face */
.vh-fiche .vh-grp { display: flex; align-items: center; gap: .3rem; min-height: 1.75rem; }
.vh-fiche .vh-grp-txt { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
/* Projet cliquable dans la colonne Origine (2026-11-19) : texte normal, couleur du module au survol */
.vh-grp-lien { color: inherit; text-decoration: none; }
.vh-grp-lien:hover, .vh-grp-lien:focus-visible { color: var(--module-primary); text-decoration: underline; }
/* Chevauchement : crochet rouge « de là à là » sous les barres, dans la frise de chaque
   feuille concernée (frise_journees.chevauchements) */
.vh-fiche .vh-tl.has-crochet { margin-bottom: 7px; }
.vh-fiche .vh-seg.conflit { top: 13px; height: 6px; background: none; border-radius: 0 0 2px 2px;
  border: 1.5px solid var(--bs-danger); border-top: 0; }
.vh-conflit-ico { color: var(--bs-danger); font-size: .72rem; flex: none; }
/* Étroit (mobile = consultation) : date, horaires, travail, statut */
@container (max-width: 760px) {
  .vh-fiche .vh-mois .vh-col-tl { display: none; }
  .vh-fiche .vh-mois tr:not(.vh-week) > :is(th, td):is(:nth-child(4), :nth-child(5), :nth-child(7), :nth-child(9)) { display: none; }
  /* Largeurs fixes en pourcentage des 4 colonnes restantes : en largeur automatique, le tableau
     dépassait sa carte d'une dizaine de pixels à 390 px (2026-11-22) */
  .vh-fiche .vh-mois { table-layout: fixed; }
  .vh-fiche .vh-mois th { width: auto !important; }
  .vh-fiche .vh-mois th:nth-child(1) { width: 22% !important; }
  .vh-fiche .vh-mois th:nth-child(3) { width: 37% !important; }
  .vh-fiche .vh-mois th:nth-child(6) { width: 15% !important; }
  .vh-fiche .vh-mois th:nth-child(8) { width: 26% !important; }
  .vh-fiche .vh-times .vh-plage { white-space: nowrap; }
  .vh-fiche .vh-times, .vh-fiche .vh-date { white-space: normal; }
  .vh-fiche .vh-plage-pause { display: none; }
  /* Bandeau de semaine qui passe à la ligne, cellules resserrées (2026-11-22) */
  .vh-fiche .vh-week td { padding: .3rem .4rem; height: auto; }
  .vh-fiche .vh-week-row, .vh-fiche .vh-week-row .tot { flex-wrap: wrap; white-space: normal; row-gap: .1rem; column-gap: .6rem; }
  .vh-fiche .vh-mois tr:not(.vh-week) > :is(th, td) { padding-left: .4rem; padding-right: .4rem; }
  .vh-fiche .vh-mois td:nth-child(8) .dx-status { white-space: normal; }
}
