﻿/* =====================================================================
   RH360 — thème
   Couleurs unies (sans dégradé), menu séparé du contenu par une ombre,
   cartes et champs de saisie arrondis, formulaires centrés.
   ===================================================================== */
:root {
    --rh-primary: #4f46e5;
    --rh-primary-dark: #3730a3;
    --rh-primary-soft: #eef2ff;
    --rh-bg: #f4f6fa;
    --rh-surface: #ffffff;
    --rh-border: #e6e9f0;
    --rh-text: #1f2937;
    --rh-muted: #6b7280;
    --rh-radius: 14px;
    --rh-radius-sm: 10px;
    --rh-shadow: 0 1px 2px rgba(16, 24, 40, .04), 0 4px 14px rgba(16, 24, 40, .05);
    --rh-shadow-lg: 0 10px 30px rgba(16, 24, 40, .10);
    /* Menu de l'espace (redéfini par espace plus bas). */
    --side-bg: #3730a3;
    --side-text: #e0e7ff;
    --side-muted: #a5b4fc;
    --side-chip: rgba(255, 255, 255, .10);
    --side-hover: rgba(255, 255, 255, .08);
    --side-active-bg: #ffffff;
    --side-active-text: #3730a3;
    --bs-primary: var(--rh-primary);
    --bs-primary-rgb: 79, 70, 229;
    --bs-link-color: var(--rh-primary);
    --bs-link-color-rgb: 79, 70, 229;
    --bs-body-color: var(--rh-text);
    --bs-border-color: var(--rh-border);
}

html { font-size: 15px; }
body { background: var(--rh-bg); color: var(--rh-text); -webkit-font-smoothing: antialiased; }

/* ---------- Boutons ---------- */
.btn { border-radius: var(--rh-radius-sm); font-weight: 500; }
.btn-lg { border-radius: 12px; }
.btn-primary {
    --bs-btn-bg: var(--rh-primary);
    --bs-btn-border-color: var(--rh-primary);
    --bs-btn-hover-bg: var(--rh-primary-dark);
    --bs-btn-hover-border-color: var(--rh-primary-dark);
    --bs-btn-active-bg: var(--rh-primary-dark);
    --bs-btn-active-border-color: var(--rh-primary-dark);
    --bs-btn-disabled-bg: var(--rh-primary);
    --bs-btn-disabled-border-color: var(--rh-primary);
    box-shadow: 0 1px 2px rgba(16, 24, 40, .08);
}
.btn-outline-primary {
    --bs-btn-color: var(--rh-primary);
    --bs-btn-border-color: var(--rh-primary);
    --bs-btn-hover-bg: var(--rh-primary);
    --bs-btn-hover-border-color: var(--rh-primary);
    --bs-btn-active-bg: var(--rh-primary-dark);
}

/* ---------- Pastilles d'icônes ---------- */
.icon-chip {
    display: inline-grid; place-items: center; width: 2.25rem; height: 2.25rem; border-radius: 10px;
    background: var(--rh-primary-soft); color: var(--rh-primary); font-size: 1.1rem; flex-shrink: 0;
}
.icon-chip-lg { width: 3.4rem; height: 3.4rem; border-radius: 16px; font-size: 1.6rem; }

.brand { font-weight: 800; font-size: 1.3rem; text-decoration: none; color: inherit; letter-spacing: -.01em; }
.brand span { color: var(--rh-primary); }

/* ---------- Site public ---------- */
body.public { background: #fff; }
.hero { padding: 4.5rem 0 3.5rem; background: #f5f7ff; border-bottom: 1px solid var(--rh-border); }
.hero h1 { font-weight: 800; letter-spacing: -.02em; }
.pack-card { border-radius: var(--rh-radius); border: 1px solid var(--rh-border); height: 100%; transition: box-shadow .2s, transform .2s; }
.pack-card:hover { box-shadow: var(--rh-shadow-lg); transform: translateY(-2px); }
.pack-card.featured { border: 2px solid var(--rh-primary); }
.feature-icon { font-size: 1.8rem; color: var(--rh-primary); }

/* Champ piège anti-robot du formulaire de souscription : invisible pour un humain. */
.hp-field { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

/* ---------- Connexion ---------- */
.auth-wrapper { min-height: calc(100vh - 160px); display: flex; align-items: center; justify-content: center; padding: 2rem 1rem; }
.auth-card { width: 100%; max-width: 420px; border: 1px solid var(--rh-border); border-radius: 18px; box-shadow: var(--rh-shadow-lg); }
/* Logiciel local : page d'activation de la licence */
.activation-card { max-width: 560px; }
.activation-logo { height: 46px; }
.activation-facts { display: grid; grid-template-columns: max-content 1fr; gap: .25rem 1rem; background: var(--rh-bg-soft, #f6f9fc); border-radius: 12px; padding: .8rem 1rem; }
.activation-facts dt { color: var(--rh-muted, #52627a); font-weight: 500; }
.activation-facts dd { margin: 0; }
.activation-choice { border-top: 1px solid var(--rh-border); padding-top: 1rem; margin-top: 1rem; }

/* ---------- Structure de l'application ---------- */
.app-shell { display: flex; min-height: 100vh; }

/* Menu latéral : en-tête (logo et société) et profil fixes, seule la liste des menus défile. */
.app-sidebar {
    /* !important : Bootstrap rend le fond des panneaux « offcanvas-lg » transparent sur grand écran. */
    background-color: var(--side-bg) !important; color: var(--side-text); z-index: 1040;
    display: flex; flex-direction: column; box-shadow: 1px 0 0 rgba(15, 23, 42, .06), 8px 0 28px rgba(15, 23, 42, .10);
}
@media (min-width: 992px) {
    .app-sidebar { width: 264px; flex-shrink: 0; position: sticky; top: 0; height: 100vh; }
}
.side-top { display: flex; align-items: center; gap: .5rem; padding: 1.15rem 1rem 1rem; border-bottom: 1px solid rgba(255, 255, 255, .08); flex-shrink: 0; }
.side-identity { display: flex; align-items: center; gap: .75rem; min-width: 0; flex: 1; }
.side-logo {
    width: 2.75rem; height: 2.75rem; border-radius: 12px; background: #fff; display: grid; place-items: center; overflow: hidden;
    flex-shrink: 0; box-shadow: 0 2px 10px rgba(0, 0, 0, .22);
}
.side-logo img { max-width: 100%; max-height: 100%; object-fit: contain; padding: .22rem; }
.side-logo-initials, .side-logo-brand { color: var(--side-bg); font-weight: 800; font-size: .95rem; letter-spacing: .02em; }
.side-logo-brand { font-size: 1.15rem; }
.side-identity-text { display: flex; flex-direction: column; min-width: 0; }
.side-company { color: #fff; font-weight: 700; font-size: .95rem; line-height: 1.2; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-space { color: var(--side-muted); font-size: .68rem; text-transform: uppercase; letter-spacing: .1em; font-weight: 600; margin-top: .15rem; }
.side-scroll { flex: 1; min-height: 0; overflow-y: auto; padding: .85rem 0 1rem; scrollbar-width: thin; scrollbar-color: rgba(255, 255, 255, .2) transparent; }
.side-scroll::-webkit-scrollbar { width: 6px; }
.side-scroll::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, .2); border-radius: 3px; }
.side-bottom { flex-shrink: 0; padding: .75rem; border-top: 1px solid rgba(255, 255, 255, .08); }
.side-profile {
    display: flex; align-items: center; gap: .65rem; width: 100%; background: rgba(255, 255, 255, .06); border: 0; border-radius: 12px;
    padding: .55rem .6rem; color: var(--side-text); text-align: left; transition: background .15s;
}
.side-profile:hover, .side-profile[aria-expanded="true"] { background: rgba(255, 255, 255, .13); }
.side-avatar {
    width: 2.2rem; height: 2.2rem; border-radius: 50%; background: var(--side-accent); color: var(--side-bg); display: grid; place-items: center;
    font-weight: 800; font-size: .78rem; flex-shrink: 0;
}
.side-profile-text { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.side-user { color: #fff; font-weight: 600; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-login { color: var(--side-muted); font-size: .72rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.side-profile > .bi { color: var(--side-muted); }
.side-profile-menu { min-width: 15rem; border-radius: 12px; box-shadow: var(--rh-shadow-lg); border: 1px solid var(--rh-border); padding: .35rem; }
.side-profile-menu .dropdown-item { border-radius: 8px; padding: .5rem .7rem; font-size: .9rem; display: flex; gap: .55rem; align-items: center; }

/* Liste des menus : sobre (icône seule, sans pastille), barre d'accent sur le menu actif. */
.sidebar-nav { list-style: none; padding: 0 .75rem; margin: 0; }
.sidebar-nav > li { margin-bottom: 2px; }
.sidebar-nav a, .sidebar-nav .sidebar-group-toggle, .sidebar-nav .disabled-link {
    position: relative; display: flex; align-items: center; gap: .75rem; width: 100%; padding: .52rem .7rem; border-radius: 9px;
    color: var(--side-text); text-decoration: none; background: none; border: 0; text-align: left; font-size: .9rem; font-weight: 500;
    transition: background .15s, color .15s;
}
.sidebar-nav > li > a > i.bi:first-child, .sidebar-nav .sidebar-group-toggle > i.bi:first-child {
    font-size: 1.05rem; width: 1.3rem; text-align: center; flex-shrink: 0; opacity: .85;
}
.sidebar-nav a:hover, .sidebar-nav .sidebar-group-toggle:hover { background: rgba(255, 255, 255, .07); color: #fff; }
.sidebar-nav > li > a.active { background: rgba(255, 255, 255, .13); color: #fff; font-weight: 600; }
.sidebar-nav > li > a.active > i.bi:first-child { opacity: 1; color: var(--side-accent); }
.sidebar-nav > li > a.active::before {
    content: ""; position: absolute; left: -.75rem; top: .5rem; bottom: .5rem; width: 3px; border-radius: 0 3px 3px 0; background: var(--side-accent);
}
.sidebar-nav .sidebar-group-toggle:not(.collapsed) { color: #fff; }
.sidebar-nav .sidebar-sub { list-style: none; margin: .15rem 0 .4rem 1.35rem; padding-left: .6rem; border-left: 1px solid rgba(255, 255, 255, .12); }
.sidebar-nav .sidebar-sub a, .sidebar-nav .sidebar-sub .disabled-link { font-size: .85rem; padding: .36rem .65rem; color: var(--side-muted); font-weight: 450; }
.sidebar-nav .sidebar-sub a:hover { color: #fff; }
.sidebar-nav .sidebar-sub a.active { background: rgba(255, 255, 255, .1); color: #fff; font-weight: 600; }
.sidebar-nav .sidebar-sub a.active::before {
    content: ""; position: absolute; left: -.68rem; top: .4rem; bottom: .4rem; width: 2px; border-radius: 2px; background: var(--side-accent);
}
.sidebar-nav .disabled-link { opacity: .5; cursor: default; }
.sidebar-nav .badge-soon { margin-left: auto; font-size: .62rem; background: rgba(255, 255, 255, .1); border-radius: 1rem; padding: .1rem .45rem; }
.sidebar-group-toggle .bi-chevron-down { margin-left: auto; font-size: .7rem; transition: transform .2s; opacity: .7; }
.sidebar-group-toggle.collapsed .bi-chevron-down { transform: rotate(-90deg); }

.app-main { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.app-topbar {
    display: flex; align-items: center; gap: .75rem; padding: .65rem 1.5rem; background: rgba(255, 255, 255, .9);
    backdrop-filter: blur(8px); border-bottom: 1px solid var(--rh-border); position: sticky; top: 0; z-index: 1020;
}
.topbar-context { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; min-width: 0; }
.topbar-actions { margin-left: auto; display: flex; align-items: center; gap: .55rem; }
.topbar-period { width: auto; min-width: 9rem; }
.topbar-alert { color: #b45309; font-size: .82rem; font-weight: 600; display: inline-flex; gap: .35rem; align-items: center; }
.topbar-avatar {
    width: 2.25rem; height: 2.25rem; border-radius: 50%; background: var(--rh-primary); color: #fff; display: grid; place-items: center;
    font-weight: 700; font-size: .76rem;
}
.btn-icon {
    position: relative; width: 2.4rem; height: 2.4rem; border-radius: 12px; display: inline-grid; place-items: center; padding: 0;
    background: #fff; border: 1px solid var(--rh-border); color: var(--rh-text); font-size: 1.1rem; transition: background .15s, color .15s;
}
.btn-icon:hover, .btn-icon[aria-expanded="true"] { background: var(--rh-primary-soft); color: var(--rh-primary); border-color: transparent; }

/* Cloche des notifications */
.notif-count {
    position: absolute; top: -6px; right: -6px; min-width: 1.2rem; height: 1.2rem; border-radius: 999px; background: #ef4444; color: #fff;
    font-size: .66rem; font-weight: 700; display: grid; place-items: center; padding: 0 .25rem; border: 2px solid #fff;
}
.notif-menu { width: 390px; max-width: calc(100vw - 1.5rem); padding: 0; border-radius: 14px; border: 1px solid var(--rh-border); box-shadow: var(--rh-shadow-lg); overflow: hidden; }
.notif-head { display: flex; justify-content: space-between; align-items: center; padding: .85rem 1rem; border-bottom: 1px solid var(--rh-border); }
.notif-list { max-height: 420px; overflow-y: auto; }
.notif-item { display: flex; gap: .75rem; padding: .75rem 1rem; border-bottom: 1px solid #f0f2f6; color: var(--rh-text); text-decoration: none; }
a.notif-item:hover { background: #f7f9fc; color: var(--rh-text); }
.notif-icon { width: 2.25rem; height: 2.25rem; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; background: var(--rh-primary-soft); color: var(--rh-primary); }
.notif-warning .notif-icon { background: #fff4e0; color: #b45309; }
.notif-danger .notif-icon { background: #fdecec; color: #b91c1c; }
.notif-body { display: flex; flex-direction: column; min-width: 0; }
.notif-title { font-weight: 650; font-size: .86rem; }
.notif-text { font-size: .8rem; color: var(--rh-muted); }
.notif-date { font-size: .7rem; color: #98a2b3; margin-top: .15rem; }
.notif-all { display: block; text-align: center; padding: .65rem; font-size: .82rem; font-weight: 600; text-decoration: none; background: #fafbfc; }
.notif-empty { padding: 1.6rem; text-align: center; color: var(--rh-muted); }
.notif-page { overflow: hidden; }
.notif-page .notif-item:last-child { border-bottom: 0; }

.app-content { padding: 1.5rem 1.1rem; width: 100%; max-width: 1440px; margin-inline: auto; }
@media (min-width: 992px) { .app-content { padding: 2rem 2.25rem; } }

/* Page de saisie (formulaire unique) : contenu centré et resserré. */
.app-content:has(> form.card.p-4), .app-content:has(> .form-page), .app-content:has(> form.form-page) { max-width: 980px; }

/* ---------- Titres, cartes, onglets ---------- */
.page-title { font-weight: 750; font-size: 1.45rem; margin-bottom: 1.25rem; letter-spacing: -.015em; }
.card-soft { background: var(--rh-surface); border: 1px solid var(--rh-border); border-radius: var(--rh-radius); box-shadow: var(--rh-shadow); }
.card-soft.p-4, .form-card { padding: 1.75rem !important; }
.form-card { padding: 1.75rem; }
.form-section-title {
    display: flex; align-items: center; gap: .5rem; font-weight: 700; font-size: .78rem; text-transform: uppercase;
    letter-spacing: .06em; color: var(--rh-muted); margin-bottom: .85rem; padding-bottom: .5rem; border-bottom: 1px solid var(--rh-border);
}
.form-section-title i { color: var(--rh-primary); font-size: 1rem; }
.card-soft h2.h6.fw-bold { font-size: .95rem; }
.stat-card .stat-value { font-size: 1.65rem; font-weight: 750; }
.stat-card .stat-label { color: var(--rh-muted); font-size: .84rem; }
.settings-tabs { border-bottom: 1px solid var(--rh-border); gap: .25rem; }
.settings-tabs .nav-link { color: var(--rh-muted); border: 0; border-bottom: 2px solid transparent; border-radius: 0; padding: .55rem .85rem; font-weight: 500; }
.settings-tabs .nav-link:hover { color: var(--rh-text); }
.settings-tabs .nav-link.active { color: var(--rh-primary); border-bottom-color: var(--rh-primary); background: transparent; font-weight: 650; }

/* ---------- Champs de saisie ---------- */
.form-label { font-weight: 600; font-size: .82rem; color: #475467; margin-bottom: .35rem; }
.form-control, .form-select {
    border-radius: var(--rh-radius-sm); border: 1px solid #d9dee8; background-color: #fbfcfe; padding: .55rem .8rem;
    transition: border-color .15s, box-shadow .15s, background-color .15s;
}
.form-control-sm, .form-select-sm { padding: .32rem .6rem; border-radius: 8px; }
.form-control:hover, .form-select:hover { border-color: #c4cbd8; }
.form-control:focus, .form-select:focus {
    background-color: #fff; border-color: var(--rh-primary); box-shadow: 0 0 0 4px color-mix(in srgb, var(--rh-primary) 15%, transparent);
}
.form-control:disabled, .form-select:disabled, fieldset:disabled .form-control { background-color: #f2f4f7; color: #667085; }
.form-check-input { border-color: #c4cbd8; }
.form-check-input:checked { background-color: var(--rh-primary); border-color: var(--rh-primary); }
.form-switch .form-check-input { width: 2.4em; }
.form-text { color: var(--rh-muted); font-size: .78rem; }
.input-group-text { border-radius: var(--rh-radius-sm); background: #f2f4f7; border-color: #d9dee8; }

/* ---------- Tableaux : en-tête sur fond, lignes aérées ---------- */
.table { --bs-table-hover-bg: #f6f8fc; margin-bottom: 0; }
.table > thead th {
    font-size: .72rem; text-transform: uppercase; letter-spacing: .05em; color: #475467; font-weight: 700; white-space: nowrap;
    background: #f1f4f9; border-bottom: 1px solid var(--rh-border); padding: .7rem .8rem; vertical-align: middle;
}
.table > thead tr:first-child > th:first-child { border-top-left-radius: 10px; }
.table > thead tr:first-child > th:last-child { border-top-right-radius: 10px; }
.table > tbody td { border-color: #eef1f6; padding: .62rem .8rem; }
.table-sm > thead th { padding: .55rem .65rem; }
.table-sm > tbody td { padding: .45rem .65rem; }
.table > tfoot td, .table > tfoot th { background: #f8fafc; font-weight: 700; }
.table-responsive { border-radius: 12px; }
.list-group-item { border-color: #eef1f6; }
.alert { border-radius: 12px; }
.badge { font-weight: 600; letter-spacing: .01em; }

/* ---------- Divers ---------- */
.logo-preview { max-height: 90px; max-width: 220px; object-fit: contain; border: 1px solid var(--rh-border); border-radius: 10px; padding: .35rem; background: #fff; }
.document-body { font-family: ui-monospace, SFMono-Regular, Consolas, monospace; font-size: .9rem; }
.document-preview { white-space: pre-wrap; background: #fff; border: 1px solid var(--rh-border); border-radius: 10px; padding: 1.5rem; font-family: Georgia, "Times New Roman", serif; }
.field-list .btn { font-size: .78rem; padding: .15rem .45rem; margin: 0 .25rem .3rem 0; }
.assistance-banner { background: #f59e0b; color: #111827; text-align: center; font-weight: 600; padding: .4rem 1rem; }
.table-audit td { vertical-align: top; font-size: .9rem; }
.text-prewrap { white-space: pre-wrap; word-break: break-word; }
.days-input { max-width: 4.5rem; }

/* Résumé des erreurs de formulaire : masqué tant qu'il n'y a pas d'erreur
   (le masquage prévu par ASP.NET passe par un style en ligne, bloqué par la politique de sécurité). */
.validation-summary-valid { display: none !important; }

/* ---------- Documents générés (impression) ---------- */
.document-sheet { background: #fff; max-width: 21cm; margin: 0 auto; padding: 2cm 2cm; border: 1px solid var(--rh-border); border-radius: 10px; }
.document-logo { max-height: 70px; max-width: 200px; object-fit: contain; margin-bottom: 1.5rem; }
.document-text { white-space: pre-wrap; font-family: Georgia, "Times New Roman", serif; font-size: 11.5pt; line-height: 1.55; }

/* ---------- Pointage ---------- */
.timesheet-grid input.form-control-sm { min-width: 4.2rem; max-width: 6rem; text-align: right; }
.timesheet-grid td:nth-child(10) input { max-width: none; min-width: 9rem; text-align: left; }
.planning-table { font-size: .8rem; }
.planning-table th, .planning-table td { text-align: center; padding: .2rem .25rem; white-space: nowrap; }
.planning-table td:first-child, .planning-table th:first-child { text-align: left; position: sticky; left: 0; background: #fff; z-index: 1; }
.planning-table .weekend { background: #f3f4f6; }
/* Planning : cases pleines et contrastées (la variable --bs-table-bg l'emporte sur le fond des tableaux Bootstrap) */
.planning-table td[class^="pl-"], .badge[class*="pl-"] { font-weight: 700; border-radius: .3rem; }
.pl-P { --bs-table-bg: #16a34a; background-color: #16a34a !important; color: #fff !important; }
.pl-A { --bs-table-bg: #dc2626; background-color: #dc2626 !important; color: #fff !important; }
.pl-C { --bs-table-bg: #2563eb; background-color: #2563eb !important; color: #fff !important; }
.pl-S { --bs-table-bg: #f59e0b; background-color: #f59e0b !important; color: #fff !important; }
.pl-F { --bs-table-bg: #7c3aed; background-color: #7c3aed !important; color: #fff !important; }
.pl-R { --bs-table-bg: #e5e7eb; background-color: #e5e7eb !important; color: #6b7280 !important; }
.pl-none { background-color: #fff !important; color: #9ca3af !important; }
.planning-table td { min-width: 1.9rem; height: 1.9rem; }
.planning-table td[class^="pl-"] { box-shadow: inset 0 0 0 2px #fff; }
.qr-print { max-width: 360px; width: 100%; image-rendering: pixelated; }
.clock-btn { font-size: 1.4rem; padding: 1.1rem; border-radius: 1rem; }
.clock-wrap { max-width: 460px; }

/* ---------- Bulletins ---------- */
.payslip-table td, .payslip-table th { font-size: .88rem; }
.payslip-totals > div { border-left: 3px solid var(--rh-primary-soft); padding-left: .6rem; }
.payslip-totals .net-to-pay { border-left-color: var(--rh-primary); }

/* ---------- États imprimables ---------- */
.report-sheet { background: #fff; border-radius: var(--rh-radius); padding: 1.25rem; border: 1px solid var(--rh-border); box-shadow: var(--rh-shadow); }
.report-table { font-size: .8rem; }
.report-table th { background: #f2f4f7; white-space: nowrap; }
.report-table td { white-space: nowrap; }
.payslip-print { page-break-after: always; break-after: page; margin-bottom: 2rem; }
.payslip-print:last-child { page-break-after: auto; break-after: auto; }
.payslip-print .identity td { padding: .15rem .4rem; font-size: .82rem; }
.letter { font-family: Georgia, "Times New Roman", serif; }

/* ---------- Espace salarié (mobile d'abord) ---------- */
.bottom-nav { display: none; }
@media (max-width: 991.98px) {
    .employee-space .app-content { padding-bottom: 5.5rem; }
    .bottom-nav {
        display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 1030; background: #fff;
        padding: .35rem .25rem calc(.35rem + env(safe-area-inset-bottom)); box-shadow: 0 -6px 20px rgba(15, 23, 42, .10);
        border-top: 1px solid var(--rh-border);
    }
    .bottom-nav a { flex: 1; text-align: center; color: var(--rh-muted); text-decoration: none; font-size: .68rem; line-height: 1.1; padding: .3rem 0; border-radius: 10px; font-weight: 500; }
    .bottom-nav a i { display: block; font-size: 1.3rem; margin-bottom: .1rem; }
    .bottom-nav a.active { color: var(--rh-primary); background: var(--rh-primary-soft); }
    .bottom-nav a.scan i { font-size: 1.55rem; color: var(--rh-primary); }
}
.kpi-card { border: 0; border-radius: var(--rh-radius); color: #fff; background: var(--rh-primary); box-shadow: var(--rh-shadow); }
.kpi-card .kpi-value { font-size: 1.9rem; font-weight: 800; line-height: 1; }
.kpi-card .kpi-label { opacity: .85; font-size: .82rem; }

/* =====================================================================
   Couleur de chaque espace (menu uni, sans dégradé)
   ===================================================================== */
/* Super Admin : rouge gazelle (conservé). */
.space-admin {
    --side-bg: #a3141f; --side-text: #fde8ea; --side-muted: #f9b9bf; --side-accent: #ffffff;
}

/* Entreprise : bleu nuit, boutons assortis. */
.space-company {
    --side-bg: #0b1b36; --side-text: #cbd7ee; --side-muted: #8fa3c8; --side-accent: #60a5fa;
    --rh-primary: #1d4ed8; --rh-primary-dark: #1e3a8a; --rh-primary-soft: #e8effd;
    --bs-primary: #1d4ed8; --bs-primary-rgb: 29, 78, 216; --bs-link-color: #1d4ed8; --bs-link-color-rgb: 29, 78, 216;
}

/* Salarié : vert foncé, boutons assortis. */
.space-employee {
    --side-bg: #0c3326; --side-text: #cfe9dd; --side-muted: #8fc5ac; --side-accent: #34d399;
    --rh-primary: #047857; --rh-primary-dark: #065f46; --rh-primary-soft: #e1f3ea;
    --bs-primary: #047857; --bs-primary-rgb: 4, 120, 87; --bs-link-color: #047857; --bs-link-color-rgb: 4, 120, 87;
}

/* ---------- Impression ---------- */
@media print {
    @page { size: A4; margin: 12mm; }
    .app-sidebar, .app-topbar, .assistance-banner, .bottom-nav, .no-print, .confirm-modal { display: none !important; }
    body, .app-content { background: #fff !important; padding: 0 !important; max-width: none !important; }
    .document-sheet { border: 0; padding: 0; max-width: none; }
    .report-sheet { box-shadow: none; padding: 0; border: 0; }
    .report-table { font-size: 7.5pt; }
    .table-responsive { overflow: visible !important; }
}

/* Bouton « retour » (au lieu d'un lien souligné) */
.btn-back {
    display: inline-flex; align-items: center; gap: .4rem; border-radius: 999px;
    padding: .3rem .9rem; font-weight: 600; text-decoration: none; margin-bottom: .35rem;
    background: var(--bs-body-bg, #fff); box-shadow: 0 1px 2px rgba(15, 23, 42, .06);
}
.btn-back:hover { text-decoration: none; transform: translateX(-2px); transition: transform .15s ease; }

/* Barre de recherche des tableaux */
.table-search { display: flex; align-items: center; gap: .5rem; max-width: 30rem; position: relative; }
.table-search .bi-search { position: absolute; left: .7rem; color: #9ca3af; pointer-events: none; }
.table-search input { padding-left: 2rem; border-radius: 999px; }

/* Période de paie affichée dans le bandeau : bouton qui ouvre le choix de l'exercice et du mois */
.btn-period { border: 1px solid var(--rh-primary, #0e7490); color: var(--rh-primary, #0e7490); border-radius: 999px; background: #fff; font-weight: 500; }
.btn-period:hover { background: var(--rh-primary, #0e7490); color: #fff; }

/* Menu horizontal de navigation (barèmes, fiche salarié, audit…) */
.rate-tabs { display: flex; flex-wrap: wrap; gap: .35rem; padding: .35rem; background: #fff; border-radius: .9rem; box-shadow: 0 1px 3px rgba(15, 23, 42, .08); }
.rate-tab { padding: .45rem .9rem; border-radius: .65rem; color: #475569; font-weight: 600; font-size: .9rem; text-decoration: none; white-space: nowrap; }
.rate-tab:hover { background: #f1f5f9; color: #0f172a; text-decoration: none; }
.rate-tab.active { background: var(--rh-primary, #4f46e5); color: #fff; box-shadow: 0 2px 6px rgba(15, 23, 42, .15); }

/* Journal d'audit : détail lisible (ancienne → nouvelle valeur) */
.audit-changes { list-style: none; padding: 0; margin: 0; }
.audit-changes li { padding: .05rem 0; }
.audit-old { color: #b91c1c; text-decoration: line-through; }
.audit-new { color: #15803d; font-weight: 600; }

/* Éditeur de documents mis en forme */
.rich-toolbar { display: flex; flex-wrap: wrap; gap: .15rem; padding: .3rem; border: 1px solid var(--rh-border, #e5e7eb); border-bottom: 0; border-radius: .6rem .6rem 0 0; background: #f8fafc; }
.rich-toolbar .btn { border: 0; min-width: 2rem; color: #334155; }
.rich-toolbar .btn:hover { background: #e2e8f0; }
.rich-sep { width: 1px; background: #cbd5e1; margin: .2rem .25rem; }
.rich-editor { min-height: 28rem; border: 1px solid var(--rh-border, #e5e7eb); border-radius: 0 0 .6rem .6rem; padding: 1.25rem 1.5rem; background: #fff; overflow: auto; }
.rich-editor:focus { outline: 2px solid var(--rh-primary, #0e7490); outline-offset: -1px; }
.rich-editor[contenteditable="false"] { background: #f8fafc; }
/* Document mis en forme (affichage, aperçu, impression) */
.document-html { font-family: Georgia, "Times New Roman", serif; font-size: 11.5pt; line-height: 1.55; }
.document-html p { margin: 0 0 .7rem; }
.document-html h1, .document-html h2, .document-html h3 { font-family: inherit; font-weight: 700; margin: .8rem 0 .6rem; }
.document-html h2 { font-size: 1.35rem; }
.document-html table { border-collapse: collapse; width: 100%; }
.document-html td, .document-html th { border: 1px solid #94a3b8; padding: .25rem .4rem; }
.document-html .doc-logo { max-height: 80px; max-width: 220px; object-fit: contain; }
.document-preview .document-html { white-space: normal; }

/* Onglets en <button> (fiche salarié) : même apparence que les liens du menu des barèmes */
button.rate-tab { border: 0; background: transparent; font-family: inherit; line-height: inherit; cursor: pointer; }
button.rate-tab:focus-visible { outline: 2px solid var(--rh-primary, #0e7490); outline-offset: 2px; }
button.rate-tab.active { background: var(--rh-primary, #4f46e5); color: #fff; }

/* Tableau de bord */
.dash-progress { width: 100%; height: .6rem; border: 0; border-radius: 999px; overflow: hidden; background: #e2e8f0; appearance: none; }
.dash-progress::-webkit-progress-bar { background: #e2e8f0; border-radius: 999px; }
.dash-progress::-webkit-progress-value { background: var(--rh-primary, #0e7490); border-radius: 999px; }
.dash-progress::-moz-progress-bar { background: var(--rh-primary, #0e7490); border-radius: 999px; }
.dash-progress-ok::-webkit-progress-value { background: #16a34a; }
.dash-progress-ok::-moz-progress-bar { background: #16a34a; }
.dash-todo li { padding: .3rem 0; border-bottom: 1px solid #f1f5f9; }
.dash-todo li:last-child { border-bottom: 0; }
.dash-todo i { color: var(--rh-primary, #0e7490); margin-right: .3rem; }
.dash-chart { width: 100%; min-width: 420px; height: auto; max-height: 220px; }
.dash-axis { stroke: #cbd5e1; stroke-width: 1; }
.dash-bar { fill: #4a97a8; }   /* contraste ≥ 3:1 sur fond blanc */
.dash-bar-current { fill: #0b4f61; }
.dash-hit { fill: transparent; }
.dash-bar-group:hover .dash-bar { fill: #0b5f75; }
.dash-value { font-size: 11px; fill: #334155; font-weight: 600; }
.dash-month { font-size: 11px; fill: #475569; }
.dash-year { font-size: 9px; fill: #94a3b8; }

/* État 9421 au format du modèle officiel de la DGI (docs/Etats_9421-2025.pdf) : écran, impression et PDF */
@page o-landscape { size: A4 landscape; margin: 6mm; }
@page o-portrait { size: A4 portrait; margin: 8mm; }
.o9421 { overflow-x: auto; padding-bottom: 1rem; }
.o-sheet { position: relative; background: #fff; color: #000; font-family: Arial, Helvetica, sans-serif; font-size: 8pt; line-height: 1.25;
    padding: 7mm; margin: 0 auto 1.25rem; box-shadow: 0 1px 6px rgba(15, 23, 42, .14); break-after: page; page-break-after: always; overflow: hidden; }
.o-landscape { page: o-landscape; width: 285mm; min-height: 198mm; }
.o-portrait { page: o-portrait; width: 194mm; min-height: 281mm; }
.o-sheet strong { font-weight: 700; }

/* Filigrane « NEANT » sur un état vide */
.o-neant { position: absolute; left: 0; right: 0; top: 22mm; text-align: center; font-size: 86pt; font-weight: 400; letter-spacing: .02em;
    color: rgba(120, 120, 120, .45); transform: rotate(-24deg); transform-origin: center; pointer-events: none; z-index: 2; }

/* En-tête des états annexes */
.o-model { text-align: right; font-weight: 700; font-size: 7.5pt; }
.o-annex { text-align: center; font-weight: 700; font-size: 11.5pt; margin-top: 1mm; }
.o-table-title { text-align: center; font-weight: 700; font-size: 11pt; margin-top: 2mm; }
.o-mt { margin-top: 6mm; }
.o-article { text-align: center; font-weight: 700; font-size: 8pt; margin-top: 1mm; }
.o-table-year { text-align: center; font-weight: 700; font-size: 9pt; margin: 3mm 0 4mm; }
.o-employer { display: flex; justify-content: space-between; gap: 6mm; font-size: 7.5pt; font-weight: 700; margin-bottom: 2mm; }
.o-employer .o-sheetno { font-weight: 400; font-style: italic; }

/* Grilles */
.o-grid { width: 100%; border-collapse: collapse; table-layout: fixed; font-size: 6.6pt; position: relative; z-index: 1; }
.o-grid th, .o-grid td { border: 1px solid #000; padding: .5mm .8mm; vertical-align: middle; overflow-wrap: anywhere; }
.o-grid thead th { font-weight: 700; text-align: center; background: #ececec; font-size: 6.3pt; line-height: 1.15; height: 8mm; }
.o-grid .o-hl { font-size: 7pt; }
.o-grid .o-num { text-align: right; white-space: nowrap; }
.o-grid .o-c { text-align: center; }
.o-grid .o-small { font-size: 5.8pt; }
.o-grid .o-l1 td { background: #f2f2f2; height: 4.6mm; }
.o-grid .o-l1 td[rowspan] { background: #fff; }
.o-grid .o-l2 td { height: 4.6mm; }
.o-grid .o-row td { height: 4.6mm; }
.o-grid .o-dark { background: #7f7f7f; }
.o-grid .o-shade { background: #ececec; }
.o-grid .o-blank { border: 0; }
.o-grid tfoot th.o-total-label { font-size: 8pt; font-weight: 700; text-align: center; background: #ececec; }
.o-grid tfoot td { font-weight: 400; height: 5.6mm; }
.o-grid .o-footnotes { border: 0; font-size: 5.3pt; font-weight: 700; line-height: 1.2; vertical-align: top; padding-right: 3mm; }
.o-grid .o-vertical { writing-mode: vertical-rl; transform: rotate(180deg); padding: 1mm 0; }
.o-grid .o-left { text-align: left; }
.o-grid .o-num-label { width: 3%; font-weight: 700; text-align: center; background: #ececec; }
.o-grid .o-x { text-align: center; font-size: 12pt; font-weight: 700; }
.o-pp thead th { font-size: 6pt; }
.o-plan tbody td { height: 4.4mm; }
.o-notes { font-size: 6.5pt; margin-top: 2mm; line-height: 1.3; }
.o-notes .o-indent { padding-left: 4mm; }

/* Largeurs de colonnes (aucun style en ligne : politique de sécurité du contenu) */
.ow-2 { width: 2%; } .ow-3 { width: 3%; } .ow-5 { width: 5%; } .ow-6 { width: 6%; } .ow-7 { width: 7%; } .ow-8 { width: 8%; } .ow-9 { width: 9%; }
.ow-10 { width: 10%; } .ow-11 { width: 11%; } .ow-12 { width: 12%; } .ow-13 { width: 13%; } .ow-14 { width: 14%; } .ow-15 { width: 15%; }
.ow-16 { width: 16%; } .ow-17 { width: 17%; } .ow-22 { width: 22%; } .ow-25 { width: 25%; } .ow-26 { width: 26%; } .ow-36 { width: 36%; }

/* Déclaration (page 1) et récépissé : logos de l'administration */
.o-logos { display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; margin-bottom: 4mm; }
.o-logo-left img { width: 45mm; }
.o-kingdom { font-weight: 700; font-style: italic; font-size: 9pt; margin: 0 0 3mm 9mm; }
.o-logo-center img { width: 30mm; }
.o-logo-right { text-align: right; }
.o-logo-right img { width: 46mm; }
.o-decl-head { display: grid; grid-template-columns: 1fr 108mm 1fr; align-items: start; margin-top: 2mm; }
.o-decl-title { grid-column: 2; border: 1px solid #000; background: #c8c8c8; text-align: center; padding: 2.5mm 2mm; }
.o-decl-title .o-big { font-size: 15pt; font-weight: 700; }
.o-decl-title .o-under { font-size: 9pt; font-weight: 700; text-decoration: underline; margin: 1mm 0 2.5mm; }
.o-decl-title .o-small { font-size: 8pt; }
.o-decl-model { grid-column: 3; font-weight: 700; font-size: 9.5pt; text-align: right; padding-top: 1mm; }
.o-decl-year { text-align: center; font-weight: 700; font-size: 12pt; margin: 4mm 0 5mm; }
.o-decl-year span { font-weight: 400; }
.o-idbox { border: 1px solid #000; background: #e4e4e4; font-size: 7.5pt; margin-bottom: 8mm; }
.o-idrow { display: grid; grid-template-columns: 58% 42%; }
.o-idrow > div { border-bottom: 1px solid #000; padding: 2mm; text-align: center; font-size: 9pt; }
.o-idrow > div + div { border-left: 1px solid #000; font-size: 8pt; }
.o-idval { font-size: 11pt; font-weight: 700; margin-top: 1.5mm; }
.o-ice { border-bottom: 1px solid #000; padding: 3mm 9mm; }
.o-identity { padding: 3mm 2mm 4mm; display: grid; gap: 3.5mm; }
.o-identity .o-right { text-align: right; padding-right: 30mm; }
.o-three { display: grid; grid-template-columns: 1fr 1fr 1fr; }
.o-staffbox { border: 1px solid #000; background: #e4e4e4; font-size: 9pt; margin-bottom: 9mm; }
.o-staff3 { display: grid; grid-template-columns: 1fr 1fr 1fr; padding: 2.5mm 3mm; border-bottom: 1px solid #000; }
.o-staffbox .o-n { font-weight: 400; font-size: 8pt; margin-left: 8mm; }
.o-staffbox .o-ref { font-size: 7pt; font-weight: 700; padding-left: 48mm; }
.o-staff3 .o-ref { padding-left: 46mm; }
.o-stafftotal { padding: 3mm 3mm 2mm 32mm; }
.o-decl-bottom { display: grid; grid-template-columns: 55% 45%; gap: 0; }
.o-admin { border: 1px solid #000; background: #e4e4e4; font-size: 9pt; }
.o-admin-title { background: #6b6b6b; color: #fff; text-align: center; font-weight: 700; font-style: italic; padding: 1mm; }
.o-admin-row { border-top: 1px solid #fff; padding: 2mm; display: flex; justify-content: space-between; font-weight: 700; }
.o-admin-row em { font-style: italic; }
.o-admin-row span { font-weight: 400; font-size: 7pt; }
.o-admin-row.o-center { justify-content: center; }
.o-stamp { background: #fff; border: 1px solid #555; height: 24mm; margin: 0 6mm 4mm; }
.o-signature { text-align: center; font-size: 9pt; padding-top: 0; }
.o-signature > div:first-child { text-align: left; padding-left: 10mm; margin-top: -4mm; margin-bottom: 6mm; }
.o-sign-title { font-weight: 700; font-size: 10.5pt; }

/* État récapitulatif */
.o-recap { width: 100%; border-collapse: collapse; font-size: 8pt; margin-bottom: 0; }
.o-recap th, .o-recap td { border: 1px solid #000; padding: 1.2mm 1.5mm; }
.o-recap th { text-align: left; font-weight: 700; width: 60%; }
.o-recap td { font-size: 10pt; text-align: right; padding-right: 15mm; }
.o-recap .o-recap-title { text-align: center; background: #e4e4e4; font-size: 11pt; }
.o-recap .o-recap-title div { font-size: 7pt; }
.o-recap .o-recap-sub { text-align: center; background: #e4e4e4; font-size: 11pt; border-bottom: 0; }
.o-recap .o-strong th { font-size: 10.5pt; }
.o-recap .o-c { text-align: center; }
.o-recap .o-small { font-size: 6.6pt; }
.o-pay { font-size: 7pt; }
.o-pay thead th { background: #ececec; }
.o-pay tbody td { height: 5mm; }
.o-recap-foot { display: flex; justify-content: space-between; margin-top: 2mm; font-size: 7pt; font-weight: 700; }
.o-recap-sign { padding-right: 25mm; }

/* Récépissé ADC046F */
.o-receipt { border: 1px solid #000; padding: 6mm 4mm 10mm; margin-top: 8mm; font-size: 9.5pt; min-height: 240mm; }
.o-receipt .o-logos { margin-bottom: 1mm; }
.o-receipt-head { display: flex; justify-content: space-between; align-items: start; font-size: 8.5pt; padding: 0 2mm; }
.o-receipt-head .o-decl-model { font-size: 7.5pt; padding-right: 8mm; }
.o-receipt-title { text-align: center; font-weight: 700; font-size: 14pt; margin-top: 8mm; }
.o-receipt-sub { text-align: center; font-weight: 700; font-size: 11pt; margin-top: 1mm; }
.o-receipt-sub span { font-size: 9pt; margin-left: 2mm; }
.o-receipt-tax { text-align: center; font-weight: 700; font-size: 8.5pt; margin-top: 10mm; }
.o-receipt-year { margin: 4mm 0 12mm 66mm; font-size: 8pt; }
.o-receipt-year span { font-size: 11pt; margin-left: 4mm; }
.o-receipt-line { margin: 0 0 6mm 10mm; font-size: 9pt; }
.o-receipt-line span { font-size: 11pt; margin-left: 6mm; }
.o-receipt-name { text-align: center; font-size: 11pt; margin-bottom: 6mm; }
.o-receipt-sep { font-weight: 700; font-size: 9pt; margin: 0 0 10mm 4mm; white-space: nowrap; overflow: hidden; }
.o-receipt-admin { display: grid; gap: 9mm; padding-left: 7mm; font-size: 9pt; }
.o-receipt-date { display: flex; justify-content: space-between; align-items: end; padding-right: 4mm; }

@media print {
    .o9421 { overflow: visible; padding: 0; }
    /* Largeur fixée en mm : sinon le navigateur met en page les feuilles paysage à la largeur d'une page portrait. */
    .o-sheet { box-shadow: none; margin: 0; padding: 0; min-height: 0; }
    .o-landscape { width: 285mm; }
    .o-portrait { width: 194mm; }
    .o-sheet:last-child { break-after: auto; page-break-after: auto; }
    .o-grid thead th, .o-grid .o-l1 td, .o-grid .o-dark, .o-grid .o-shade, .o-idbox, .o-staffbox, .o-admin, .o-admin-title, .o-decl-title,
    .o-recap .o-recap-title, .o-recap .o-recap-sub, .o-grid tfoot th.o-total-label, .o-grid .o-num-label { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* =====================================================================
   Formulaires : champs modernes, validation lisible, fenêtre de confirmation
   ===================================================================== */
.page-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: .75rem; margin-bottom: 1.25rem; }
.page-head .page-title { margin-bottom: .2rem; }
.page-sub { color: var(--rh-muted); margin: 0; font-size: .9rem; }
.empty-state { text-align: center; color: var(--rh-muted); padding: 2.5rem 1rem; }
.empty-state i { font-size: 2rem; display: block; margin-bottom: .5rem; opacity: .6; }

.form-control, .form-select { min-height: 2.6rem; }
.form-control-sm, .form-select-sm { min-height: 2rem; }
textarea.form-control { min-height: 5rem; }
.form-control::placeholder { color: #a0a8b8; }
.form-select { background-position: right .8rem center; }
.form-check { padding-top: .1rem; }
.form-check-input { width: 1.15em; height: 1.15em; margin-top: .2em; cursor: pointer; }
.form-check-input:focus { box-shadow: 0 0 0 4px color-mix(in srgb, var(--rh-primary) 15%, transparent); border-color: var(--rh-primary); }
.form-switch .form-check-input { width: 2.4em; height: 1.3em; margin-top: .1em; }
.form-check-label { cursor: pointer; }
.input-validation-error, .form-control.is-invalid, .form-select.is-invalid { border-color: #ef4444 !important; background-color: #fff8f8; }
.input-validation-error:focus { box-shadow: 0 0 0 4px rgba(239, 68, 68, .15) !important; }
.field-validation-error { display: flex; align-items: center; gap: .3rem; font-size: .78rem; margin-top: .3rem; color: #dc2626; font-weight: 500; }
.field-validation-error::before { font-family: "bootstrap-icons"; content: "\f33a"; font-size: .85rem; }
.validation-summary-errors { border-radius: 12px; background: #fef2f2; color: #991b1b; border: 1px solid #fecaca; padding: .8rem 1rem; font-size: .88rem; }
.validation-summary-errors ul { margin: 0; padding-left: 1.1rem; }
.card-soft .form-section-title { margin-top: .25rem; }
.form-actions { display: flex; flex-wrap: wrap; gap: .5rem; justify-content: flex-end; padding-top: 1rem; margin-top: 1rem; border-top: 1px solid var(--rh-border); }

.confirm-modal .modal-content { border: 0; border-radius: 18px; box-shadow: 0 24px 60px rgba(15, 23, 42, .28); }
.confirm-modal .modal-body { text-align: center; padding: 1.9rem 1.9rem .4rem; }
.confirm-icon {
    width: 3.3rem; height: 3.3rem; border-radius: 50%; margin: 0 auto 1rem; display: grid; place-items: center; font-size: 1.45rem;
    background: var(--rh-primary-soft); color: var(--rh-primary);
}
.confirm-danger .confirm-icon { background: #fdecec; color: #dc2626; }
.confirm-title { font-size: 1.12rem; font-weight: 700; margin-bottom: .45rem; }
.confirm-text { color: var(--rh-muted); margin: 0; white-space: pre-line; }
.confirm-modal .modal-footer { border: 0; justify-content: center; gap: .5rem; padding: 1.1rem 1.9rem 1.6rem; }
.confirm-modal .modal-footer .btn { min-width: 8rem; }

/* Action de page en haut à droite (ex. « Supprimer la fiche ») */
.page-corner-action { float: right; margin-top: .1rem; position: relative; z-index: 2; }

/* Synthèse en texte d'un rapprochement */
.report-lines { display: grid; gap: .45rem; margin: .4rem 0 .9rem; }
.report-line { display: flex; gap: .6rem; align-items: flex-start; padding: .6rem .85rem; border-radius: 10px; font-size: .9rem; border: 1px solid var(--rh-border); background: #fff; }
.report-line i { margin-top: .1rem; }
.report-line.is-head { font-weight: 700; background: var(--rh-primary-soft); border-color: transparent; color: var(--rh-primary-dark); }
.report-line.is-ok { border-color: #bbf7d0; background: #f0fdf4; color: #166534; }
.report-line.is-gap { border-color: #fecaca; background: #fef2f2; color: #991b1b; font-weight: 600; }

/* =====================================================================
   Tableau de bord : cartes regroupées, boutons-icônes, aucun texte souligné
   ===================================================================== */
.kpi { display: flex; gap: .85rem; align-items: flex-start; height: 100%; padding: 1.1rem 1.15rem; background: #fff; border: 1px solid var(--rh-border); border-radius: var(--rh-radius); box-shadow: var(--rh-shadow); }
.kpi-icon { width: 2.75rem; height: 2.75rem; border-radius: 12px; display: grid; place-items: center; font-size: 1.25rem; flex-shrink: 0; }
.kpi-blue { background: #e8effd; color: #1d4ed8; } .kpi-green { background: #e3f6ec; color: #047857; }
.kpi-violet { background: #efeafe; color: #6d28d9; } .kpi-amber { background: #fef3e2; color: #b45309; }
.kpi-label { color: var(--rh-muted); font-size: .8rem; font-weight: 600; }
.kpi-value { font-size: 1.45rem; font-weight: 750; line-height: 1.25; letter-spacing: -.01em; }
.kpi-value small { font-size: .8rem; font-weight: 500; color: var(--rh-muted); }
.kpi-sub { font-size: .76rem; color: var(--rh-muted); }
.dash-card { padding: 1.15rem 1.25rem; }
.dash-card-head { display: flex; justify-content: space-between; align-items: center; gap: .5rem; margin-bottom: .9rem; }
.dash-card-title { display: inline-flex; align-items: center; gap: .5rem; font-weight: 700; font-size: .92rem; }
.dash-card-title i { color: var(--rh-primary); }
.btn-icon-sm { width: 2rem; height: 2rem; border-radius: 10px; font-size: .95rem; }
.dash-shortcuts { display: grid; grid-template-columns: repeat(auto-fill, minmax(118px, 1fr)); gap: .6rem; }
.dash-shortcut { display: flex; flex-direction: column; align-items: center; gap: .45rem; padding: .85rem .5rem; border-radius: 12px; border: 1px solid var(--rh-border);
    text-decoration: none; color: var(--rh-text); font-size: .8rem; font-weight: 600; text-align: center; transition: border-color .15s, box-shadow .15s, transform .15s; }
.dash-shortcut span { width: 2.4rem; height: 2.4rem; border-radius: 12px; display: grid; place-items: center; background: var(--rh-primary-soft); color: var(--rh-primary); font-size: 1.15rem; }
.dash-shortcut:hover { border-color: var(--rh-primary); color: var(--rh-text); box-shadow: var(--rh-shadow); transform: translateY(-1px); }
.dash-todo-list { display: grid; gap: .4rem; }
.dash-todo-item { display: flex; align-items: center; gap: .7rem; padding: .55rem .65rem; border-radius: 10px; text-decoration: none; color: var(--rh-text); background: #f8fafc; font-size: .86rem; }
.dash-todo-item:hover { background: var(--rh-primary-soft); color: var(--rh-text); }
.dash-todo-icon { width: 2rem; height: 2rem; border-radius: 9px; display: grid; place-items: center; background: #fff; color: var(--rh-muted); flex-shrink: 0; }
.dash-todo-label { flex: 1; }
.dash-todo-count { min-width: 1.8rem; padding: .1rem .5rem; border-radius: 999px; background: #e9edf3; color: var(--rh-muted); font-weight: 700; font-size: .78rem; text-align: center; }
.dash-todo-item.has-items .dash-todo-icon { color: var(--rh-primary); }
.dash-todo-item.has-items .dash-todo-count { background: var(--rh-primary); color: #fff; }
.dash-stats { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.dash-stats > div { background: #f8fafc; border-radius: 10px; padding: .65rem .75rem; display: flex; flex-direction: column; }
.dash-stats-wide { grid-column: 1 / -1; }
.dash-stat-value { font-weight: 750; font-size: 1.15rem; }
.dash-stat-value small { font-size: .74rem; color: var(--rh-muted); font-weight: 500; }
.dash-stat-label { font-size: .74rem; color: var(--rh-muted); }
.dash-bar { fill: color-mix(in srgb, var(--rh-primary) 55%, #fff); }
.dash-bar-current, .dash-bar-group:hover .dash-bar { fill: var(--rh-primary); }

/* =====================================================================
   Bulletins de paie : présentation compacte, liste des salariés dans un panneau défilant
   ===================================================================== */
.payslip-panel { display: flex; flex-direction: column; overflow: hidden; }
@media (min-width: 992px) { .payslip-panel { position: sticky; top: .75rem; height: calc(100vh - 12.5rem); min-height: 20rem; } }
.payslip-search { display: grid; gap: .4rem; padding: .7rem; border-bottom: 1px solid var(--rh-border); }
.search-field { position: relative; }
.search-field .bi-search { position: absolute; left: .65rem; top: 50%; transform: translateY(-50%); color: #9ca3af; font-size: .85rem; pointer-events: none; }
.search-field .form-control { padding-left: 1.9rem; border-radius: 999px; }
.payslip-legend { display: flex; gap: .7rem; align-items: center; padding: .4rem .8rem; font-size: .7rem; color: var(--rh-muted); border-bottom: 1px solid var(--rh-border); background: #fafbfc; }
.payslip-list { flex: 1; overflow-y: auto; max-height: 60vh; scrollbar-width: thin; }
@media (min-width: 992px) { .payslip-list { max-height: none; } }
.payslip-item { display: flex; align-items: center; gap: .55rem; padding: .45rem .8rem; text-decoration: none; color: var(--rh-text); border-bottom: 1px solid #f1f3f7; font-size: .84rem; }
.payslip-item:hover { background: #f6f8fc; color: var(--rh-text); }
.payslip-item.active { background: var(--rh-primary-soft); box-shadow: inset 3px 0 0 var(--rh-primary); }
.payslip-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.payslip-name { font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.payslip-meta { font-size: .72rem; color: var(--rh-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.payslip-net { font-size: .78rem; font-weight: 600; white-space: nowrap; font-variant-numeric: tabular-nums; }
.payslip-empty { display: block; padding: 1rem; color: var(--rh-muted); font-size: .85rem; }
.dot { display: inline-block; width: .55rem; height: .55rem; border-radius: 50%; background: #cbd5e1; flex-shrink: 0; }
.dot-ok { background: #16a34a; } .dot-draft { background: #f59e0b; }
.payslip-detail .card-soft.p-3 { padding: .85rem 1rem !important; margin-bottom: .75rem !important; }
.payslip-detail h3.h6 { font-size: .82rem; text-transform: uppercase; letter-spacing: .05em; color: var(--rh-muted); margin-bottom: .6rem; }
.payslip-detail .form-label { font-size: .74rem; }
.report-line.is-info { color: var(--rh-muted); background: #f8fafc; }
.app-content a:not(.btn):not(.dropdown-item):not(.nav-link) { text-decoration: none; font-weight: 500; }
.app-content a:not(.btn):not(.dropdown-item):not(.nav-link):hover { text-decoration: underline; }

/* Super Admin : suivi des paiements des abonnements */
.pay-stat { display: flex; flex-direction: column; gap: .15rem; padding: .7rem .9rem; border-radius: 12px; background: #f8fafc; border: 1px solid var(--rh-border); height: 100%; }
.pay-stat span { font-size: .76rem; color: var(--rh-muted); font-weight: 600; }
.pay-stat strong { font-size: 1.05rem; }
.pay-stat.pay-ok { background: #f0fdf4; border-color: #bbf7d0; }
.pay-stat.pay-late { background: #fef2f2; border-color: #fecaca; }
.pay-stat.pay-late strong { color: #b91c1c; }
.pay-inline { display: inline-flex; gap: .3rem; align-items: center; }
.pay-inline .form-control, .pay-inline .form-select { width: auto; max-width: 9.5rem; }
#paiements td.text-capitalize { white-space: nowrap; }

/* =====================================================================
   Site public iRH360 — couleurs du logo : bleu marine, turquoise, bleu
   ===================================================================== */
body.public {
    --brand-navy: #0b2a4f; --brand-teal: #16c3a6; --brand-cyan: #12a8c8; --brand-blue: #1565c0;
    --brand-grad: linear-gradient(120deg, #16c3a6 0%, #12a8c8 48%, #1565c0 100%);
    --rh-primary: #0f8fb3; --rh-primary-dark: #0b2a4f; --rh-primary-soft: #e4f6f8;
    --bs-primary: #0f8fb3; --bs-primary-rgb: 15, 143, 179; --bs-link-color: #0f8fb3; --bs-link-color-rgb: 15, 143, 179;
    background: #fff; color: #1d2b3f; font-size: 1rem;
}
.public main { overflow-x: clip; }

/* En-tête */
.pub-header { position: sticky; top: 0; z-index: 1030; background: rgba(255, 255, 255, .82); backdrop-filter: saturate(160%) blur(12px);
    border-bottom: 1px solid transparent; transition: border-color .2s, box-shadow .2s; }
.pub-header.is-scrolled { border-bottom-color: #e8edf3; box-shadow: 0 6px 24px rgba(11, 42, 79, .06); }
.pub-header .navbar { padding: .7rem 0; }
.pub-brand img { height: 34px; width: auto; display: block; }
@media (min-width: 992px) { .pub-brand img { height: 38px; } }
.pub-nav .nav-link { color: #3b4a5e; font-weight: 500; padding: .5rem .9rem !important; border-radius: 10px; }
.pub-nav .nav-link:hover { color: var(--brand-navy); background: #f2f6fa; }
.pub-toggler { border: 0; width: 42px; height: 42px; border-radius: 12px; display: inline-flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px; background: #f2f6fa; }
.pub-toggler:focus { box-shadow: none; }
.pub-toggler span { width: 18px; height: 2px; border-radius: 2px; background: var(--brand-navy); display: block; transition: transform .2s; }
.pub-toggler[aria-expanded="true"] span:first-child { transform: translateY(3.5px) rotate(45deg); }
.pub-toggler[aria-expanded="true"] span:last-child { transform: translateY(-3.5px) rotate(-45deg); }
@media (max-width: 991.98px) { .pub-header .navbar-collapse { padding: .75rem 0 .5rem; } }

/* Boutons */
.public .btn { border-radius: 12px; font-weight: 600; padding: .62rem 1.15rem; }
.pub-btn-login, .pub-btn-primary { background: var(--brand-grad); color: #fff; border: 0; box-shadow: 0 8px 22px rgba(18, 168, 200, .32); }
.public .pub-btn-login { padding: .55rem 1.15rem; display: inline-flex; align-items: center; gap: .45rem; border-radius: 999px; }
.pub-btn-login i { transition: transform .2s; }
.pub-btn-login:hover, .pub-btn-primary:hover { color: #fff; filter: brightness(1.05); box-shadow: 0 10px 28px rgba(18, 168, 200, .42); transform: translateY(-1px); }
.pub-btn-login:hover i { transform: translateX(3px); }
.public .pub-btn-primary { padding: .78rem 1.4rem; }
.pub-btn-ghost { background: transparent; color: var(--brand-navy); border: 1.5px solid #d6dfe9; display: inline-flex; align-items: center; gap: .45rem; }
.pub-btn-ghost:hover { border-color: var(--brand-navy); color: var(--brand-navy); background: #f7fafc; }
.pub-btn-outline { background: #fff; color: var(--brand-navy); border: 1.5px solid #cfdbe7; }
.pub-btn-outline:hover { border-color: var(--brand-cyan); color: var(--brand-cyan); }
.pub-btn-white { background: #fff; color: var(--brand-navy); border: 0; }
.pub-btn-white:hover { background: #eefaf9; color: var(--brand-navy); }
.pub-btn-white-ghost { background: transparent; color: #fff; border: 1.5px solid rgba(255, 255, 255, .6); }
.pub-btn-white-ghost:hover { background: rgba(255, 255, 255, .12); color: #fff; border-color: #fff; }

/* Accueil */
.pub-hero { position: relative; padding: 4.5rem 0 4rem; }
@media (min-width: 992px) { .pub-hero { padding: 6rem 0 5.5rem; } }
.pub-hero-glow { position: absolute; inset: -20% -10% auto auto; width: 70%; height: 120%; pointer-events: none;
    background: radial-gradient(closest-side, rgba(22, 195, 166, .18), transparent 70%), radial-gradient(closest-side at 70% 60%, rgba(21, 101, 192, .16), transparent 70%); filter: blur(10px); }
.pub-eyebrow { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-cyan); margin-bottom: 1rem; }
.pub-eyebrow-light { color: #9ff0e2; }
.pub-title { font-size: clamp(2.1rem, 4.6vw, 3.6rem); font-weight: 800; letter-spacing: -.035em; line-height: 1.08; color: var(--brand-navy); margin-bottom: 1.25rem; }
.pub-lead { font-size: 1.15rem; color: #52627a; max-width: 36rem; margin-bottom: 2rem; }
.pub-cta { display: flex; flex-wrap: wrap; gap: .75rem; }
.pub-chips { display: flex; flex-wrap: wrap; gap: .5rem; list-style: none; padding: 0; margin: 2rem 0 0; }
.pub-chips li { font-size: .8rem; font-weight: 600; color: #3b4a5e; padding: .3rem .8rem; border-radius: 999px; background: #f2f6fa; border: 1px solid #e3eaf2; }
.pub-gradient-text { background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Aperçu de l'application (CSS) */
.pub-preview { position: relative; min-height: 380px; max-width: 520px; margin-inline: auto; }
.pub-preview-card { position: absolute; background: #fff; border-radius: 18px; border: 1px solid #e6edf5; box-shadow: 0 24px 60px rgba(11, 42, 79, .14); }
.pub-preview-main { inset: 0 8% auto 0; padding: 1.25rem 1.4rem; }
.pv-head { display: flex; align-items: center; gap: .35rem; margin-bottom: 1.1rem; }
.pv-dot { width: .55rem; height: .55rem; border-radius: 50%; background: #dbe4ee; }
.pv-title { margin-left: .5rem; font-size: .8rem; font-weight: 700; color: #6a7a90; }
.pv-row { display: flex; justify-content: space-between; padding: .5rem 0; border-bottom: 1px dashed #e8eef4; font-size: .9rem; color: var(--brand-navy); font-variant-numeric: tabular-nums; }
.pv-row.muted { color: #7a889c; }
.pv-net { display: flex; justify-content: space-between; align-items: center; margin-top: 1rem; padding: .85rem 1rem; border-radius: 12px; background: var(--brand-grad); color: #fff; }
.pv-net strong { font-size: 1.15rem; }
.pub-preview-chart { width: 46%; right: 0; bottom: 0; padding: 1rem 1.1rem; }
.pv-label { font-size: .75rem; font-weight: 700; color: #6a7a90; margin-bottom: .6rem; }
.pv-bars { display: flex; align-items: flex-end; gap: .4rem; height: 70px; }
.pv-bars i { flex: 1; border-radius: 5px 5px 2px 2px; background: linear-gradient(180deg, #12a8c8, #16c3a6); opacity: .85; }
.pv-bars i:nth-child(1) { height: 45%; } .pv-bars i:nth-child(2) { height: 60%; } .pv-bars i:nth-child(3) { height: 52%; }
.pv-bars i:nth-child(4) { height: 72%; } .pv-bars i:nth-child(5) { height: 66%; } .pv-bars i:nth-child(6) { height: 92%; background: linear-gradient(180deg, #1565c0, #12a8c8); opacity: 1; }
.pub-preview-badge { left: -2%; bottom: 14%; display: flex; gap: .7rem; align-items: center; padding: .8rem 1rem; }
.pub-preview-badge strong { display: block; font-size: .88rem; color: var(--brand-navy); }
.pub-preview-badge small { color: #7a889c; font-size: .75rem; }
.pv-check { width: 2rem; height: 2rem; border-radius: 50%; background: var(--brand-grad); position: relative; flex-shrink: 0; }
.pv-check::after { content: ""; position: absolute; left: .7rem; top: .45rem; width: .5rem; height: .9rem; border: solid #fff; border-width: 0 2.5px 2.5px 0; transform: rotate(45deg); }
@media (max-width: 575.98px) {
    .pub-preview { min-height: 450px; }
    .pub-preview-main { inset: 0 0 auto 0; }
    .pub-preview-chart { width: 55%; }
    .pub-preview-badge { left: 0; bottom: 4%; }
}

/* Bandeau de chiffres clés */
.pub-strip { border-block: 1px solid #edf1f6; background: #fbfcfe; }
.pub-strip-grid { display: grid; grid-template-columns: repeat(2, 1fr); }
@media (min-width: 992px) { .pub-strip-grid { grid-template-columns: repeat(4, 1fr); } }
.pub-strip-grid > div { padding: 1.6rem 1.25rem; display: flex; flex-direction: column; gap: .2rem; }
.pub-strip-grid > div + div { border-left: 1px solid #edf1f6; }
@media (max-width: 991.98px) { .pub-strip-grid > div:nth-child(3) { border-left: 0; } .pub-strip-grid > div:nth-child(n+3) { border-top: 1px solid #edf1f6; } }
.pub-strip strong { font-size: 1.1rem; color: var(--brand-navy); }
.pub-strip span { font-size: .85rem; color: #6a7a90; }

/* Sections */
.pub-section { padding: 5rem 0; }
.pub-section-soft { background: linear-gradient(180deg, #f6f9fc, #fff); }
.pub-section-head { text-align: center; max-width: 40rem; margin: 0 auto 3rem; }
.pub-kicker { display: inline-block; font-size: .78rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; color: var(--brand-cyan); margin-bottom: .6rem; }
.pub-h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); font-weight: 800; letter-spacing: -.025em; line-height: 1.15; color: var(--brand-navy); margin-bottom: 1rem; }
.pub-text { color: #52627a; font-size: 1.02rem; }
.pub-checks { list-style: none; padding: 0; margin: 0; display: grid; gap: .9rem; }
.pub-checks li { position: relative; padding: 1rem 1.2rem 1rem 3.1rem; border-radius: 14px; background: #f6f9fc; color: #52627a; }
.pub-checks li strong { display: block; color: var(--brand-navy); }
.pub-checks li::before { content: ""; position: absolute; left: 1.1rem; top: 1.2rem; width: 1.2rem; height: 1.2rem; border-radius: 50%; background: var(--brand-grad); }
.pub-checks li::after { content: ""; position: absolute; left: 1.52rem; top: 1.42rem; width: .32rem; height: .6rem; border: solid #fff; border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Fonctionnalités (numérotées, sans icônes) */
.pub-features { display: grid; gap: 1.25rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .pub-features { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1200px) { .pub-features { grid-template-columns: repeat(3, 1fr); } }
.pub-feature { position: relative; padding: 1.75rem; border-radius: 18px; background: #fff; border: 1px solid #e8eef4; transition: transform .2s, box-shadow .2s, border-color .2s; overflow: hidden; }
.pub-feature::before { content: ""; position: absolute; left: 0; top: 0; height: 3px; width: 100%; background: var(--brand-grad); transform: scaleX(0); transform-origin: left; transition: transform .3s; }
.pub-feature:hover { transform: translateY(-3px); box-shadow: 0 18px 40px rgba(11, 42, 79, .08); border-color: transparent; }
.pub-feature:hover::before { transform: scaleX(1); }
.pub-feature-num { font-size: .9rem; font-weight: 800; letter-spacing: .05em; background: var(--brand-grad); -webkit-background-clip: text; background-clip: text; color: transparent; }
.pub-feature h3 { font-size: 1.15rem; font-weight: 700; color: var(--brand-navy); margin: .6rem 0 .5rem; }
.pub-feature p { color: #5d6c82; font-size: .94rem; margin: 0; }

/* Tarifs */
.pub-pack { position: relative; height: 100%; display: flex; flex-direction: column; padding: 2rem 1.75rem; border-radius: 20px; background: #fff; border: 1px solid #e3eaf2; transition: transform .2s, box-shadow .2s; }
.pub-pack:hover { transform: translateY(-3px); box-shadow: 0 20px 44px rgba(11, 42, 79, .09); }
.pub-pack.is-featured { border: 2px solid transparent; background: linear-gradient(#fff, #fff) padding-box, var(--brand-grad) border-box; box-shadow: 0 22px 50px rgba(18, 168, 200, .18); }
.pub-pack-flag { position: absolute; top: -.8rem; left: 50%; transform: translateX(-50%); padding: .25rem .8rem; border-radius: 999px; background: var(--brand-grad); color: #fff; font-size: .72rem; font-weight: 700; letter-spacing: .05em; text-transform: uppercase; }
.pub-pack-tag { font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--brand-cyan); }
.pub-pack-name { font-size: 1.35rem; font-weight: 800; color: var(--brand-navy); margin: .35rem 0 .5rem; }
.pub-pack-desc { color: #5d6c82; font-size: .92rem; }
.pub-pack-price { margin: .5rem 0 1.25rem; }
.pub-pack-price .amount { font-size: 2.4rem; font-weight: 800; letter-spacing: -.03em; color: var(--brand-navy); }
.pub-pack-price .amount-sm { font-size: 1.5rem; }
.pub-pack-price .unit { color: #6a7a90; font-size: .9rem; }
.pub-pack-list { list-style: none; padding: 0; margin: 0 0 1.5rem; flex-grow: 1; display: grid; gap: .55rem; }
.pub-pack-list li { position: relative; padding-left: 1.5rem; font-size: .92rem; color: #3b4a5e; }
.pub-pack-list li::before { content: ""; position: absolute; left: .2rem; top: .25rem; width: .35rem; height: .7rem; border: solid var(--brand-cyan); border-width: 0 2px 2px 0; transform: rotate(45deg); }

/* Bandeau contact */
.pub-cta-band { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1.5rem; padding: 2.75rem; border-radius: 26px; color: #fff;
    background: radial-gradient(circle at 85% 20%, rgba(255, 255, 255, .18), transparent 40%), var(--brand-grad); box-shadow: 0 24px 60px rgba(21, 101, 192, .25); }
@media (max-width: 575.98px) { .pub-cta-band { padding: 2rem 1.5rem; } }
.pub-cta-band h2 { font-size: clamp(1.5rem, 2.6vw, 2.1rem); font-weight: 800; letter-spacing: -.02em; margin-bottom: .5rem; }
.pub-cta-band p { margin: 0; opacity: .92; max-width: 36rem; }
.pub-contact-line { margin-top: .75rem !important; display: flex; flex-wrap: wrap; gap: 1.25rem; font-weight: 600; }
.pub-contact-line a { color: #fff; }
.pub-cta-band-actions { display: flex; flex-wrap: wrap; gap: .75rem; }

/* Pied de page */
.pub-footer { border-top: 1px solid #edf1f6; padding: 3rem 0 1.5rem; background: #fbfcfe; }
.pub-footer-grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2rem; align-items: flex-start; }
.pub-footer-logo { height: 34px; }
.pub-footer-tag { color: #6a7a90; margin: .75rem 0 0; font-size: .92rem; }
.pub-footer-links { display: flex; flex-wrap: wrap; gap: .5rem 1.75rem; }
.pub-footer-links a { color: #3b4a5e; text-decoration: none; font-weight: 500; font-size: .92rem; }
.pub-footer-links a:hover { color: var(--brand-cyan); }
.pub-footer-bottom { margin-top: 2.25rem; padding-top: 1.25rem; border-top: 1px solid #edf1f6; color: #8593a6; font-size: .85rem; }

/* Connexion */
.pub-auth { padding: 3rem 1rem 4rem; display: flex; justify-content: center; }
.pub-auth-card { width: 100%; max-width: 980px; display: grid; grid-template-columns: 1fr; border-radius: 26px; overflow: hidden; background: #fff; border: 1px solid #e6edf5; box-shadow: 0 30px 70px rgba(11, 42, 79, .12); }
@media (min-width: 992px) { .pub-auth-card { grid-template-columns: 1fr 1fr; } }
.pub-auth-aside { position: relative; display: none; padding: 3rem; color: #fff; background: linear-gradient(150deg, #0b2a4f 0%, #0f4f86 55%, #12a8c8 100%); overflow: hidden; }
@media (min-width: 992px) { .pub-auth-aside { display: flex; align-items: flex-end; } }
.pub-auth-aside .pub-hero-glow { inset: -30% -40% auto auto; width: 120%; opacity: .9; }
.pub-auth-aside-inner { position: relative; }
.pub-auth-aside h2 { font-size: 2rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.15; margin-bottom: .75rem; }
.pub-auth-aside p { opacity: .85; }
.pub-auth-points { list-style: none; padding: 0; margin: 1.5rem 0 0; display: grid; gap: .55rem; }
.pub-auth-points li { position: relative; padding-left: 1.4rem; font-weight: 500; }
.pub-auth-points li::before { content: ""; position: absolute; left: 0; top: .5rem; width: .5rem; height: .5rem; border-radius: 50%; background: #16c3a6; box-shadow: 0 0 0 4px rgba(22, 195, 166, .25); }
.pub-auth-form { padding: 2.5rem 1.75rem; }
@media (min-width: 576px) { .pub-auth-form { padding: 3rem; } }
.pub-auth-logo { height: 40px; margin-bottom: 1.75rem; }
.pub-auth-title { font-size: 1.6rem; font-weight: 800; color: var(--brand-navy); letter-spacing: -.02em; margin-bottom: .35rem; }
.pub-auth-sub { color: #6a7a90; margin-bottom: 1.75rem; }
.pub-auth-help { color: #6a7a90; font-size: .86rem; margin: 1.5rem 0 0; }
.public .form-control:focus { border-color: var(--brand-cyan); box-shadow: 0 0 0 4px rgba(18, 168, 200, .15); }

/* Zone dangereuse (suppression définitive) */
.danger-zone { border: 1px solid #fecaca; background: #fff7f7; border-radius: 12px; padding: 1rem; }
.danger-zone .danger-title { font-weight: 700; color: #b91c1c; margin-bottom: .4rem; display: flex; gap: .4rem; align-items: center; }
.danger-zone p { font-size: .82rem; color: #7f1d1d; }

/* En-tête des documents imprimés (bulletin, états) : logo de taille limitée, n° d'affiliation CNSS seul */
.doc-head { display: grid; grid-template-columns: auto 1fr auto; gap: 1rem; align-items: center; padding-bottom: .75rem; margin-bottom: .9rem; border-bottom: 2px solid #1f2937; }
.doc-logo { max-height: 58px; max-width: 150px; width: auto; height: auto; object-fit: contain; }
.doc-company { font-size: .82rem; line-height: 1.35; }
.doc-company-name { font-weight: 800; font-size: 1rem; text-transform: uppercase; letter-spacing: .02em; }
.doc-title { text-align: right; }
.doc-title-main { font-weight: 800; font-size: 1.15rem; letter-spacing: .03em; text-transform: uppercase; white-space: nowrap; }
.doc-title-sub { font-size: .85rem; color: #4b5563; text-transform: capitalize; }

/* États larges (journal, livre de paie) : impression en paysage */
@page report-landscape { size: A4 landscape; margin: 8mm; }
@media print {
    .report-landscape { page: report-landscape; width: 281mm; }
    .report-landscape .report-table { font-size: 6.5pt; }
    .report-landscape .table-responsive { max-height: none !important; overflow: visible !important; }
}

/* Grandes listes : le tableau défile dans son cadre (et non toute la page), en-têtes fixes. */
@media screen {
    .app-content .card-soft .table-responsive, .app-content .card .table-responsive {
        max-height: calc(100vh - 240px); overflow: auto; scrollbar-width: thin;
    }
    .app-content .table-responsive > .table > thead th { position: sticky; top: 0; z-index: 2; box-shadow: inset 0 -1px 0 var(--rh-border); }
    .app-content .planning-table thead th:first-child { left: 0; z-index: 4; }
    .app-content .planning-table tbody td:first-child { z-index: 1; }
    .app-content .payslip-detail .table-responsive, .app-content .report-sheet .table-responsive, .app-content #paiements .table-responsive { max-height: none; }
}

/* Bulletins : variables du mois en barre repliable */
.vars-card { overflow: hidden; }
.vars-bar { width: 100%; display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; padding: .7rem 1rem; background: #fff; border: 0; text-align: left; }
.vars-bar:hover { background: #f8fafc; }
.vars-title { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--rh-muted); display: inline-flex; gap: .45rem; align-items: center; }
.vars-title i { color: var(--rh-primary); }
.vars-summary { display: flex; flex-wrap: wrap; gap: .4rem .9rem; font-size: .8rem; color: var(--rh-muted); }
.vars-summary strong { color: var(--rh-text); }
.vars-chevron { margin-left: auto; transition: transform .2s; color: var(--rh-muted); }
.vars-bar:not(.collapsed) .vars-chevron { transform: rotate(180deg); }
.vars-body { padding: 0 1rem .9rem; border-top: 1px solid var(--rh-border); padding-top: .8rem; }

/* Formulaire public de demande d'abonnement : compact, en trois étapes */
.pub-sub-card { max-width: 1060px; }
@media (min-width: 992px) { .pub-sub-card { grid-template-columns: 5fr 7fr; } }
.pub-steps { list-style: none; counter-reset: step; padding: 0; margin: 1.75rem 0 0; display: grid; gap: .9rem; }
.pub-steps li { counter-increment: step; position: relative; padding-left: 2.6rem; display: flex; flex-direction: column; }
.pub-steps li::before { content: counter(step); position: absolute; left: 0; top: 0; width: 1.9rem; height: 1.9rem; border-radius: 50%; display: grid; place-items: center;
    background: rgba(255, 255, 255, .14); border: 1px solid rgba(255, 255, 255, .35); font-weight: 700; font-size: .85rem; }
.pub-steps span { opacity: .75; font-size: .85rem; }
.pub-sub-form fieldset { margin-bottom: 1.1rem; }
.pub-sub-form legend { font-size: .82rem; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--brand-navy); display: flex; align-items: center; gap: .5rem; margin-bottom: .6rem; }
.pub-sub-form legend span { width: 1.4rem; height: 1.4rem; border-radius: 50%; display: grid; place-items: center; background: var(--brand-grad); color: #fff; font-size: .72rem; }
.pub-sub-form .form-label { font-size: .78rem; margin-bottom: .2rem; }
.pub-sub-form .form-control { min-height: 2.4rem; padding: .45rem .75rem; }
.pub-pack-pick { display: grid; gap: .5rem; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); }
.pub-pick { position: relative; display: flex; flex-direction: column; gap: .1rem; padding: .7rem .85rem; border: 1.5px solid #dbe4ee; border-radius: 12px; cursor: pointer; transition: border-color .15s, box-shadow .15s; }
.pub-pick input { position: absolute; opacity: 0; pointer-events: none; }
.pub-pick-name { font-weight: 700; color: var(--brand-navy); font-size: .9rem; }
.pub-pick-price { font-size: .78rem; color: #6a7a90; }
.pub-pick:hover { border-color: var(--brand-cyan); }
.pub-pick:has(input:checked) { border-color: transparent; background: linear-gradient(#fff, #fff) padding-box, var(--brand-grad) border-box; box-shadow: 0 8px 22px rgba(18, 168, 200, .18); }
.pub-pick:has(input:focus-visible) { outline: 3px solid rgba(18, 168, 200, .35); outline-offset: 2px; }

/* Catalogue de modèles de documents iRH360 (import par la société) */
.catalog-grid { display: grid; gap: .6rem; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.catalog-item { display: flex; justify-content: space-between; align-items: center; gap: .75rem; padding: .7rem .85rem; border: 1px solid var(--rh-border); border-radius: 12px; background: #fbfcfe; }

/* Site public : application Windows */
.pub-app { display: grid; grid-template-columns: auto 1fr auto; gap: 1.75rem; align-items: center; padding: 2rem; border-radius: 22px; border: 1px solid #e3eaf2; background: linear-gradient(135deg, #f6fbfd, #fff); }
@media (max-width: 991.98px) { .pub-app { grid-template-columns: 1fr; text-align: center; } .pub-app-icon { margin: 0 auto; } }
.pub-app-icon { width: 88px; height: 88px; border-radius: 22px; background: #fff; display: grid; place-items: center; box-shadow: 0 14px 36px rgba(11, 42, 79, .12); }
.pub-app-icon img { width: 64px; height: 64px; }
.pub-app .pub-h2 { font-size: clamp(1.4rem, 2.4vw, 1.9rem); }
.pub-app-cta { display: flex; flex-direction: column; align-items: center; gap: .5rem; }
.pub-app-cta .btn { display: inline-flex; align-items: center; gap: .55rem; white-space: nowrap; }
.pub-app-meta { font-size: .78rem; color: #6a7a90; }

/* Mots de passe : bouton afficher / masquer, indicateur de force animé */
.pwd-field { position: relative; }
.pwd-field .form-control { padding-right: 2.8rem; }
.pwd-toggle { position: absolute; right: .35rem; top: 50%; transform: translateY(-50%); border: 0; background: transparent; color: #8593a6; width: 2.2rem; height: 2.2rem; border-radius: 8px; }
.pwd-toggle:hover { color: var(--rh-primary); background: #f2f6fa; }
.pwd-card { max-width: 460px; }
.pwd-logo { height: 34px; margin-bottom: 1.25rem; }
.pwd-strength { margin: .5rem 0 1rem; }
.pwd-meter { display: grid; grid-template-columns: repeat(4, 1fr); gap: .3rem; margin-bottom: .35rem; }
.pwd-meter span { height: .4rem; border-radius: 999px; background: #e5eaf1; transform-origin: left; transition: background .35s ease, transform .35s ease; }
.pwd-label { font-size: .78rem; font-weight: 700; color: #8593a6; transition: color .3s; }
.pwd-rules { list-style: none; padding: 0; margin: .45rem 0 0; display: flex; flex-wrap: wrap; gap: .3rem .5rem; }
.pwd-rules li { font-size: .72rem; color: #8593a6; padding: .15rem .55rem; border-radius: 999px; background: #f2f5f9; transition: background .25s, color .25s; }
.pwd-rules li::before { content: "○ "; }
.pwd-rules li.ok { background: #e3f6ec; color: #047857; }
.pwd-rules li.ok::before { content: "✓ "; }
.pwd-strength[data-level="1"] .pwd-meter span:nth-child(-n+1) { background: #ef4444; animation: pwd-grow .35s ease; }
.pwd-strength[data-level="1"] .pwd-label { color: #dc2626; }
.pwd-strength[data-level="2"] .pwd-meter span:nth-child(-n+2) { background: #f59e0b; animation: pwd-grow .35s ease; }
.pwd-strength[data-level="2"] .pwd-label { color: #d97706; }
.pwd-strength[data-level="3"] .pwd-meter span:nth-child(-n+3) { background: #22c55e; animation: pwd-grow .35s ease; }
.pwd-strength[data-level="3"] .pwd-label { color: #16a34a; }
.pwd-strength[data-level="4"] .pwd-meter span { background: #059669; animation: pwd-grow .35s ease; }
.pwd-strength[data-level="4"] .pwd-label { color: #047857; }
@keyframes pwd-grow { from { transform: scaleX(.2); } to { transform: scaleX(1); } }
.pwd-match { font-size: .78rem; margin-top: .3rem; min-height: 1.1rem; }
.pwd-match.is-ok { color: #16a34a; }
.pwd-match.is-ko { color: #dc2626; }
.is-desktop .pub-auth { min-height: 100vh; align-items: center; padding: 1.5rem; }

/* Application : plus de barre de défilement de la page. Menu et barre du haut fixes, seul le contenu défile
   (barre très fine, visible seulement au survol) ; les grandes listes défilent dans leur propre cadre. */
@media screen and (min-width: 992px) {
    html:has(body.app), body.app { height: 100%; overflow: hidden; }
    body.app .app-shell { height: 100vh; min-height: 0; }
    body.app .app-main { height: 100vh; overflow-y: auto; overflow-x: hidden; scrollbar-width: thin; scrollbar-color: transparent transparent; scrollbar-gutter: stable; }
    body.app .app-main:hover { scrollbar-color: rgba(100, 116, 139, .35) transparent; }
    body.app .app-main::-webkit-scrollbar { width: 6px; }
    body.app .app-main::-webkit-scrollbar-thumb { background: transparent; border-radius: 3px; }
    body.app .app-main:hover::-webkit-scrollbar-thumb { background: rgba(100, 116, 139, .35); }
    body.app .app-content { padding-bottom: 1.25rem; }
    /* Les tableaux occupent la hauteur disponible sans dépasser l'écran. */
    .app-content .card-soft .table-responsive, .app-content .card .table-responsive { max-height: calc(100vh - 260px); }
}
@media print {
    html:has(body.app), body.app, body.app .app-shell, body.app .app-main { height: auto !important; overflow: visible !important; }
}

/* Connexion : tient sur un écran d'ordinateur portable sans défilement (et dans l'application Windows) */
@media (max-height: 920px) and (min-width: 992px) {
    .pub-auth { padding: 1.25rem 1rem; }
    .pub-auth-form { padding: 2rem 2.75rem; }
    .pub-auth-aside { padding: 2.25rem; }
    .pub-auth-logo { height: 32px; margin-bottom: 1rem; }
    .pub-auth-title { font-size: 1.35rem; }
    .pub-auth-sub { margin-bottom: 1rem; }
    .pub-auth .form-control-lg { min-height: 2.6rem; font-size: 1rem; padding: .5rem .85rem; }
    .pub-auth .mb-3 { margin-bottom: .7rem !important; }
    .pub-auth .mb-4 { margin-bottom: 1rem !important; }
    .pub-auth-help { margin-top: .9rem; }
    .pub-auth-aside h2 { font-size: 1.6rem; }
}
.is-desktop .pub-auth { min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.is-desktop .pub-auth-card { max-height: calc(100vh - 2rem); }

/* =====================================================================
   Connexion plein écran (site et application Windows)
   ===================================================================== */
.is-bare main { min-height: 100vh; }
.login { display: grid; grid-template-columns: 1fr; min-height: 100vh; background: #fff; }
@media (min-width: 992px) { .login { grid-template-columns: minmax(0, 1.05fr) minmax(0, 1fr); height: 100vh; } }

.login-aside { position: relative; overflow: hidden; display: none; flex-direction: column; justify-content: space-between; padding: 3rem 3.5rem;
    color: #fff; background: linear-gradient(150deg, #071d38 0%, #0b2a4f 35%, #0f5a8f 70%, #12a8c8 100%); }
@media (min-width: 992px) { .login-aside { display: flex; } }
.login-orb { position: absolute; border-radius: 50%; filter: blur(60px); opacity: .55; pointer-events: none; }
.login-orb-1 { width: 420px; height: 420px; right: -120px; top: -100px; background: #16c3a6; }
.login-orb-2 { width: 360px; height: 360px; left: -140px; bottom: -120px; background: #1565c0; }
.login-ring { position: absolute; right: -6vw; bottom: 8vh; font-size: clamp(9rem, 17vw, 16rem); font-weight: 800; letter-spacing: -.05em; line-height: 1;
    color: transparent; -webkit-text-stroke: 2px rgba(255, 255, 255, .12); pointer-events: none; user-select: none; }
.login-aside-top { position: relative; display: flex; align-items: center; gap: .8rem; }
.login-mark { width: 52px; height: 52px; border-radius: 16px; background: #fff; display: grid; place-items: center; box-shadow: 0 10px 30px rgba(0, 0, 0, .25); }
.login-mark img { width: 38px; height: 38px; }
.login-brand { font-size: 1.6rem; font-weight: 800; letter-spacing: -.02em; }
.login-aside-body { position: relative; max-width: 560px; }
.login-eyebrow { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem .8rem; font-size: clamp(.85rem, 1.1vw, 1.05rem); font-weight: 700;
    letter-spacing: .14em; text-transform: uppercase; color: #9ff0e2; margin-bottom: 1.4rem; }
.login-eyebrow i { width: .4rem; height: .4rem; border-radius: 50%; background: #16c3a6; box-shadow: 0 0 0 4px rgba(22, 195, 166, .25); }
.login-aside h2 { font-size: clamp(2.2rem, 3.6vw, 3.4rem); font-weight: 800; line-height: 1.08; letter-spacing: -.03em; margin-bottom: 1.1rem; }
.login-aside p { font-size: clamp(1rem, 1.25vw, 1.2rem); opacity: .88; margin-bottom: 2rem; }
.login-features { display: grid; gap: .8rem; }
.login-features > div { display: flex; gap: .9rem; align-items: center; padding: .85rem 1rem; border-radius: 16px;
    background: rgba(255, 255, 255, .08); border: 1px solid rgba(255, 255, 255, .12); backdrop-filter: blur(6px); }
.login-features span { width: 2.6rem; height: 2.6rem; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0;
    background: linear-gradient(135deg, #16c3a6, #1565c0); font-size: 1.15rem; }
.login-features strong { display: block; font-size: 1rem; }
.login-features small { opacity: .75; font-size: .85rem; }
.login-aside-foot { position: relative; font-size: .8rem; opacity: .6; }

.login-main { display: flex; flex-direction: column; padding: 1.25rem 1.5rem; overflow-y: auto; }
@media (min-width: 992px) { .login-main { padding: 1.5rem 3rem; } }
.login-top { display: flex; justify-content: space-between; align-items: center; }
.login-back { color: #52627a; text-decoration: none; font-weight: 600; font-size: .9rem; display: inline-flex; gap: .4rem; align-items: center; }
.login-back:hover { color: var(--brand-navy); }
.login-form { width: 100%; max-width: 420px; margin: auto; padding: 1.5rem 0; }
.login-logo { height: 42px; margin-bottom: 1.6rem; }
.login-form h1 { font-size: 1.9rem; font-weight: 800; color: var(--brand-navy); letter-spacing: -.02em; margin-bottom: .3rem; }
.login-sub { color: #6a7a90; margin-bottom: 1.6rem; }
.login-input { position: relative; }
.login-input > .bi { position: absolute; left: .9rem; top: 50%; transform: translateY(-50%); color: #8593a6; font-size: 1.05rem; pointer-events: none; z-index: 2; }
.login-input .form-control { padding-left: 2.6rem; min-height: 3rem; border-radius: 12px; }
.login-options { display: flex; justify-content: space-between; align-items: center; margin: .6rem 0 1.4rem; font-size: .9rem; }
.login-hint { color: var(--brand-cyan); font-weight: 600; cursor: help; font-size: .85rem; }
.login-form .pub-btn-primary { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; border-radius: 12px; }
.login-help { color: #6a7a90; font-size: .85rem; margin: 1.2rem 0 0; }
.login-help + .login-help { margin-top: .5rem; }
.is-desktop .login-main { justify-content: center; }

/* =====================================================================
   Site public — v2 : moins de blanc, sections en couleur (palette du logo)
   ===================================================================== */
.pub-hero { background:
    radial-gradient(900px 500px at 85% 10%, rgba(18, 168, 200, .16), transparent 60%),
    radial-gradient(700px 420px at 0% 100%, rgba(22, 195, 166, .14), transparent 60%),
    linear-gradient(180deg, #f2f9fc 0%, #ffffff 100%); }
@media (min-width: 992px) { .pub-hero { padding: 4.5rem 0 4rem; } }
.pub-section { padding: 4.25rem 0; }

/* Bandeau de chiffres clés : bleu nuit */
.pub-strip { background: linear-gradient(120deg, #0b2a4f, #0f4f86); border: 0; }
.pub-strip strong { color: #fff; }
.pub-strip span { color: #a9c3dd; }
.pub-strip-grid > div + div { border-left-color: rgba(255, 255, 255, .12); }
@media (max-width: 991.98px) { .pub-strip-grid > div:nth-child(n+3) { border-top-color: rgba(255, 255, 255, .12); } }

/* Présentation : fond turquoise très clair, points clés en cartes */
.pub-section-tint { background: linear-gradient(180deg, #eaf7f8 0%, #f4fafc 100%); }
.pub-section-tint .pub-checks li { background: #fff; box-shadow: 0 10px 28px rgba(11, 42, 79, .06); border: 1px solid #e1eef2; }

/* Fonctionnalités : bloc bleu nuit, cartes vitrées */
.pub-section-dark { position: relative; overflow: hidden; color: #fff;
    background: radial-gradient(700px 400px at 90% 0%, rgba(22, 195, 166, .22), transparent 60%),
                radial-gradient(600px 380px at 0% 100%, rgba(21, 101, 192, .35), transparent 60%),
                linear-gradient(160deg, #071d38 0%, #0b2a4f 55%, #0d3f6d 100%); }
.pub-section-dark .pub-kicker { color: #6ee7d3; }
.pub-section-dark .pub-h2 { color: #fff; }
.pub-section-dark .pub-feature { background: rgba(255, 255, 255, .06); border-color: rgba(255, 255, 255, .12); backdrop-filter: blur(6px); }
.pub-section-dark .pub-feature:hover { background: rgba(255, 255, 255, .1); border-color: rgba(110, 231, 211, .4); box-shadow: 0 18px 40px rgba(0, 0, 0, .25); }
.pub-section-dark .pub-feature h3 { color: #fff; }
.pub-section-dark .pub-feature p { color: #b8cbe0; }
.pub-section-dark .pub-feature-num { font-size: 1.6rem; background: linear-gradient(120deg, #6ee7d3, #38bdf8); -webkit-background-clip: text; background-clip: text; color: transparent; }

/* Application Windows : fond clair teinté */
.pub-section-app { background: #f4fafc; padding-top: 3.5rem; padding-bottom: 0; }
.pub-section-app .pub-app { background: #fff; box-shadow: 0 18px 44px rgba(11, 42, 79, .08); border-color: #e1eef2; }

/* Tarifs : fond dégradé clair, offre recommandée en bleu nuit */
.pub-section-pricing { background: linear-gradient(180deg, #f4fafc 0%, #e8f4f8 100%); }
.pub-section-pricing .pub-pack { box-shadow: 0 14px 36px rgba(11, 42, 79, .07); border-color: #dceaf0; }
.pub-pack.is-featured { color: #fff; border: 0; background: linear-gradient(160deg, #0b2a4f 0%, #0f4f86 60%, #1279b0 100%); box-shadow: 0 26px 60px rgba(11, 42, 79, .35); }
@media (min-width: 992px) { .pub-pack.is-featured { transform: translateY(-10px); } .pub-pack.is-featured:hover { transform: translateY(-13px); } }
.pub-pack.is-featured .pub-pack-name, .pub-pack.is-featured .pub-pack-price .amount { color: #fff; }
.pub-pack.is-featured .pub-pack-tag { color: #6ee7d3; }
.pub-pack.is-featured .pub-pack-desc, .pub-pack.is-featured .pub-pack-price .unit { color: #b8cbe0; }
.pub-pack.is-featured .pub-pack-list li { color: #e2ecf7; }
.pub-pack.is-featured .pub-pack-list li::before { border-color: #6ee7d3; }
.pub-pack.is-featured .pub-pack-flag { background: linear-gradient(120deg, #16c3a6, #12a8c8); box-shadow: 0 6px 16px rgba(0, 0, 0, .2); }

/* Contact : suite du fond des tarifs */
.pub-section-contact { background: #e8f4f8; padding-top: 0; }
.pub-footer { background: #fff; }

/* =====================================================================
   Application : formulaires plus compacts (moins de défilement vertical et horizontal)
   ===================================================================== */
@media screen {
    body.app .app-content { padding-top: 1.1rem; }
    @media (min-width: 992px) { body.app .app-content { padding: 1.25rem 1.75rem 1rem; } }
    body.app .page-title { font-size: 1.3rem; margin-bottom: .75rem; }
    body.app .page-head { margin-bottom: .85rem; }
    body.app .card-soft.p-4, body.app .form-card, body.app .card.p-4 { padding: 1.1rem 1.25rem !important; }
    body.app .card-soft.p-3, body.app .card.p-3 { padding: .85rem 1rem !important; }
    body.app .form-label { font-size: .76rem; margin-bottom: .2rem; }
    body.app .form-control, body.app .form-select { min-height: 2.25rem; padding: .38rem .7rem; font-size: .9rem; }
    body.app .form-select { padding-right: 2.2rem; }
    body.app .form-control-sm, body.app .form-select-sm { min-height: 1.9rem; padding: .25rem .55rem; font-size: .84rem; }
    body.app textarea.form-control { min-height: 4rem; }
    body.app .form-text { font-size: .72rem; margin-top: .15rem; }
    body.app .form-section-title { margin-bottom: .55rem; padding-bottom: .35rem; font-size: .72rem; }
    body.app form .row.g-3, body.app .card .row.g-3 { --bs-gutter-y: .65rem; --bs-gutter-x: .85rem; }
    body.app form .mb-4, body.app .card-soft .mb-4 { margin-bottom: 1rem !important; }
    body.app form .mb-3 { margin-bottom: .7rem !important; }
    body.app .btn { padding: .4rem .85rem; font-size: .9rem; }
    body.app .btn-sm { padding: .25rem .6rem; font-size: .82rem; }
    body.app .rate-tabs { margin-bottom: .75rem !important; }
    body.app .alert { padding: .6rem .85rem; margin-bottom: .75rem; }
    /* Les champs longs n'imposent jamais une barre horizontale. */
    body.app .app-content { overflow-x: hidden; }
    body.app .form-control, body.app .form-select { max-width: 100%; }
}

/* Tableaux triables : deux petites flèches dans l'en-tête (la flèche active est colorée) */
.table-sortable thead th[data-sort] { cursor: pointer; user-select: none; position: relative; padding-right: 1.4rem; }
.table-sortable thead th[data-sort]::before, .table-sortable thead th[data-sort]::after {
    content: ""; position: absolute; right: .5rem; border-left: 4px solid transparent; border-right: 4px solid transparent; opacity: .35; }
.table-sortable thead th[data-sort]::before { top: calc(50% - 6px); border-bottom: 4px solid currentColor; }
.table-sortable thead th[data-sort]::after { top: calc(50% + 2px); border-top: 4px solid currentColor; }
.table-sortable thead th[aria-sort="ascending"]::before, .table-sortable thead th[aria-sort="descending"]::after { opacity: 1; color: var(--rh-primary); }
.table-sortable thead th[data-sort]:hover { color: var(--rh-primary); }
.account-cnss { margin-bottom: 1rem; max-width: 420px; }
.account-email { display: flex; gap: .3rem; min-width: 240px; }

/* =====================================================================
   Journal de paie (deux lignes par salarié) et bordereau CNSS
   ===================================================================== */
.journal-table { width: 100%; border-collapse: collapse; font-size: .74rem; font-variant-numeric: tabular-nums; }
.journal-table th, .journal-table td { border: 1px solid #c9d2de; padding: .22rem .35rem; white-space: nowrap; }
.journal-table thead th { background: #e8eef6; color: #1f2d3d; font-weight: 700; text-align: center; font-size: .68rem; line-height: 1.15; white-space: normal; }
.journal-table thead tr:first-child th { border-bottom-style: dashed; }
.journal-table tbody tr:first-child td { border-bottom-style: dashed; border-bottom-color: #dfe5ee; }
.journal-table tbody tr:last-child td { border-bottom: 1.5px solid #9aa8bb; }
.journal-table tbody:nth-of-type(even) td { background: #fafbfd; }
.journal-table .num { text-align: right; }
.journal-table .ctr { text-align: center; }
.journal-table .name { max-width: 14rem; overflow: hidden; text-overflow: ellipsis; font-weight: 600; }
.journal-table .strong { font-weight: 700; }
.journal-table tfoot td { background: #eef3f9; font-weight: 700; }
.journal-table tfoot tr:first-child td { border-top: 2px solid #5b6f8a; border-bottom-style: dashed; }

.bpc { max-width: 820px; margin-inline: auto; }
.bpc-meta { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem; font-size: .85rem; margin-bottom: .9rem; }
.bpc-table { width: 100%; border-collapse: collapse; margin-bottom: 1rem; font-size: .85rem; font-variant-numeric: tabular-nums; }
.bpc-table caption { caption-side: top; padding: .45rem .7rem; background: #0b5d8f; color: #fff; font-weight: 700; font-size: .82rem; text-transform: uppercase; letter-spacing: .03em; }
.bpc-table th { background: #e6f0f7; color: #0b3d5e; font-weight: 700; font-size: .78rem; padding: .4rem .7rem; border: 1px solid #bcd3e3; text-align: center; }
.bpc-table td { padding: .4rem .7rem; border: 1px solid #d3e1ea; }
.bpc-table th:first-child { text-align: left; width: 40%; }
.bpc-table .num { text-align: right; }
.bpc-table tfoot td { background: #f2f7fa; font-weight: 700; }
.bpc-table tfoot td:first-child { text-align: right; }
.bpc-global { display: flex; justify-content: space-between; align-items: center; padding: .7rem 1rem; border: 2px solid #0b5d8f; background: #e6f0f7; color: #0b3d5e; font-weight: 700; }
.bpc-global strong { font-size: 1.15rem; }
@media print {
    .journal-table { font-size: 6.3pt; }
    .journal-table thead th { font-size: 6pt; }
    .journal-table tbody { break-inside: avoid; }
    .bpc-table caption, .bpc-table th, .bpc-global, .journal-table thead th, .journal-table tfoot td { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
}

/* =====================================================================
   Tableau de bord v2 : accès rapides en tête, grille tenant dans l'écran
   ===================================================================== */
.dash-top { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem 1.25rem; margin-bottom: 1rem; }
.dash-period { font-size: .78rem; color: var(--rh-primary); text-decoration: none; margin-left: .35rem; }
.dash-period:hover { text-decoration: underline; }
.dash-quick { display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.dash-quick-item { display: inline-flex; align-items: center; gap: .5rem; padding: .4rem .8rem .4rem .45rem; border-radius: 999px; background: #fff; border: 1px solid var(--rh-border);
    color: var(--rh-text); text-decoration: none; font-size: .82rem; font-weight: 600; box-shadow: 0 2px 8px rgba(15, 23, 42, .04); transition: border-color .15s, box-shadow .15s, transform .15s; }
.dash-quick-item[hidden] { display: none; }
.dash-quick-item span { width: 1.9rem; height: 1.9rem; border-radius: 50%; display: grid; place-items: center; background: var(--rh-primary-soft); color: var(--rh-primary); font-size: .95rem; }
.dash-quick-item:hover { border-color: var(--rh-primary); color: var(--rh-text); box-shadow: var(--rh-shadow); transform: translateY(-1px); }
.dash-quick-gear { width: 2.3rem; height: 2.3rem; border-radius: 50%; border: 1px dashed #b8c3d1; background: transparent; color: var(--rh-muted); display: grid; place-items: center; }
.dash-quick-gear:hover, .dash-quick-gear[aria-expanded="true"] { border-color: var(--rh-primary); color: var(--rh-primary); background: var(--rh-primary-soft); }
.dash-quick-menu { width: 260px; padding: .4rem 0; border-radius: 12px; box-shadow: 0 18px 40px rgba(15, 23, 42, .16); border-color: var(--rh-border); }
.dash-quick-menu-head { padding: .35rem .9rem .5rem; font-weight: 700; font-size: .85rem; display: flex; justify-content: space-between; align-items: baseline; border-bottom: 1px solid var(--rh-border); margin-bottom: .25rem; }
.dash-quick-menu-head small { color: var(--rh-muted); font-weight: 600; }
.dash-quick-option { display: flex; align-items: center; gap: .55rem; padding: .32rem .9rem; font-size: .84rem; cursor: pointer; margin: 0; }
.dash-quick-option:hover { background: #f6f8fc; }
.dash-quick-option i { color: var(--rh-primary); width: 1rem; }
.dash-quick-option .form-check-input { margin: 0; }
.dash-quick-option:has(input:disabled) { opacity: .45; cursor: not-allowed; }
.dash-quick-menu-foot { padding: .45rem .9rem .2rem; font-size: .72rem; color: var(--rh-muted); border-top: 1px solid var(--rh-border); margin-top: .25rem; }

.dash-kpis .kpi { padding: .85rem 1rem; }
.dash-kpis .kpi-value { font-size: 1.3rem; }
.dash-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .dash-grid { grid-template-columns: 1fr 1fr; } .dash-chart-card { grid-column: 1 / -1; } }
@media (min-width: 1200px) { .dash-grid { grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr) minmax(0, 1fr); } .dash-chart-card { grid-column: auto; } }
.dash-grid > .dash-card, .dash-col > .dash-card { padding: .9rem 1rem; }
.dash-col { display: flex; flex-direction: column; gap: 1rem; min-width: 0; }
.dash-chart-card { display: flex; flex-direction: column; min-width: 0; }
.dash-chart-wrap { flex: 1; display: flex; align-items: center; overflow-x: auto; }
.dash-chart-card .dash-chart { min-width: 360px; max-height: 200px; }
.dash-hint { font-size: .72rem; color: var(--rh-muted); margin: .3rem 0 0; }

/* Paie du mois : anneaux d'avancement */
.dash-pay { display: block; text-decoration: none; color: var(--rh-text); transition: box-shadow .15s, transform .15s; }
.dash-pay:hover { color: var(--rh-text); box-shadow: 0 14px 34px rgba(15, 23, 42, .1); transform: translateY(-1px); }
.dash-pay-go { color: var(--rh-muted); transition: transform .15s, color .15s; }
.dash-pay:hover .dash-pay-go { color: var(--rh-primary); transform: translateX(3px); }
.dash-rings { display: grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.dash-ring { display: flex; align-items: center; gap: .6rem; padding: .5rem .6rem; border-radius: 12px; background: #f8fafc; }
.dash-ring-chart { position: relative; width: 3.4rem; height: 3.4rem; flex-shrink: 0; }
.dash-ring-chart svg { width: 100%; height: 100%; transform: rotate(-90deg); }
.ring-track { fill: none; stroke: #e5eaf1; stroke-width: 4.5; }
.ring-value { fill: none; stroke: var(--rh-primary); stroke-width: 4.5; stroke-linecap: round; transition: stroke-dasharray .6s ease; }
.dash-ring.is-ok .ring-value { stroke: #16a34a; }
.dash-ring-pct { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 800; font-size: .82rem; font-variant-numeric: tabular-nums; }
.dash-ring-pct small { font-size: .6rem; font-weight: 600; margin-left: 1px; }
.dash-ring-label { display: flex; flex-direction: column; font-size: .74rem; color: var(--rh-muted); line-height: 1.25; }
.dash-ring-label strong { color: var(--rh-text); font-size: .95rem; font-variant-numeric: tabular-nums; }
.dash-stats-compact { gap: .45rem; }
.dash-stats-compact > div { padding: .45rem .6rem; }
.dash-stats-compact .dash-stat-value { font-size: 1rem; }
.dash-grid .dash-todo-list { gap: .35rem; }
.dash-grid .dash-todo-item { padding: .45rem .55rem; font-size: .83rem; }
.dash-grid .dash-todo-icon { width: 1.8rem; height: 1.8rem; }

/* =====================================================================
   Tableau de bord v3 (« dx ») : bandeau en dégradé, cartes aérées, graphiques
   ===================================================================== */
.dx { --dx-navy: #0b2a4f; --dx-blue: #2563eb; --dx-sky: #38bdf8; --dx-teal: #14b8a6; --dx-ink: #0f172a; --dx-soft: #64748b;
    display: flex; flex-direction: column; gap: 1rem; }
.dx-hero { position: relative; z-index: 10; border-radius: 22px; padding: 1.25rem 1.4rem 1.3rem; color: #fff;
    background: radial-gradient(600px 260px at 92% -20%, rgba(56, 189, 248, .45), transparent 60%),
                radial-gradient(520px 260px at 0% 120%, rgba(20, 184, 166, .35), transparent 60%),
                linear-gradient(125deg, #071d38 0%, #0b2a4f 40%, #0f4f86 78%, #1279b0 100%);
    box-shadow: 0 22px 50px -18px rgba(11, 42, 79, .55); }
.dx-hero::after { content: ""; position: absolute; right: 0; top: 0; width: 230px; height: 200px; border-top-right-radius: 22px; pointer-events: none;
    background: radial-gradient(circle at 100% 0, transparent 92px, rgba(255, 255, 255, .05) 93px, rgba(255, 255, 255, .05) 130px, transparent 131px); }
.dx-hero-top { position: relative; z-index: 5; display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1.1rem; }
.dx-eyebrow { display: inline-flex; align-items: center; gap: .4rem; font-size: .8rem; font-weight: 600; color: #9ff0e2; letter-spacing: .02em; }
.dx-title { font-size: clamp(1.35rem, 2vw, 1.75rem); font-weight: 800; letter-spacing: -.02em; margin: .15rem 0 .45rem; color: #fff; }
.dx-period { display: inline-flex; align-items: center; gap: .45rem; padding: .3rem .75rem; border-radius: 999px; font-size: .8rem; font-weight: 600;
    color: #fff; text-decoration: none; background: rgba(255, 255, 255, .12); border: 1px solid rgba(255, 255, 255, .18); backdrop-filter: blur(6px); }
.dx-period:hover { background: rgba(255, 255, 255, .2); color: #fff; }
.dx-period .bi-chevron-down { font-size: .65rem; opacity: .75; }

.dx-quick { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; }
.dx-quick-item { display: inline-flex; align-items: center; gap: .55rem; padding: .35rem .85rem .35rem .35rem; border-radius: 999px; font-size: .82rem; font-weight: 600;
    color: #fff; text-decoration: none; background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .16); backdrop-filter: blur(8px);
    transition: background .2s, transform .2s, box-shadow .2s; }
.dx-quick-item[hidden] { display: none; }
.dx-quick-item span { width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; background: #fff; color: var(--dx-navy); font-size: .95rem;
    box-shadow: 0 6px 14px rgba(0, 0, 0, .18); }
.dx-quick-item:hover { color: #fff; background: rgba(255, 255, 255, .22); transform: translateY(-2px); box-shadow: 0 12px 24px -10px rgba(0, 0, 0, .45); }
.dx-quick-gear { width: 2.5rem; height: 2.5rem; border-radius: 50%; display: grid; place-items: center; color: #fff; background: transparent;
    border: 1px dashed rgba(255, 255, 255, .45); transition: background .2s, transform .3s; }
.dx-quick-gear:hover, .dx-quick-gear[aria-expanded="true"] { background: rgba(255, 255, 255, .15); transform: rotate(90deg); }

.dx-kpis { position: relative; z-index: 1; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .75rem; }
@media (max-width: 1199.98px) { .dx-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 575.98px) { .dx-kpis { grid-template-columns: 1fr; } }
.dx-kpi { display: flex; gap: .8rem; align-items: center; padding: .85rem 1rem; border-radius: 16px; background: rgba(255, 255, 255, .09);
    border: 1px solid rgba(255, 255, 255, .14); backdrop-filter: blur(10px); transition: background .2s, transform .2s; }
.dx-kpi:hover { background: rgba(255, 255, 255, .14); transform: translateY(-2px); }
.dx-kpi-icon { width: 2.7rem; height: 2.7rem; flex-shrink: 0; border-radius: 13px; display: grid; place-items: center; font-size: 1.2rem; color: #fff;
    background: linear-gradient(135deg, var(--dx-teal), var(--dx-blue)); box-shadow: 0 10px 20px -8px rgba(20, 184, 166, .7); }
.dx-kpi:nth-child(2) .dx-kpi-icon { background: linear-gradient(135deg, #22c55e, #0ea5e9); }
.dx-kpi:nth-child(3) .dx-kpi-icon { background: linear-gradient(135deg, #a78bfa, #6366f1); box-shadow: 0 10px 20px -8px rgba(99, 102, 241, .7); }
.dx-kpi:nth-child(4) .dx-kpi-icon { background: linear-gradient(135deg, #fbbf24, #f97316); box-shadow: 0 10px 20px -8px rgba(249, 115, 22, .7); }
.dx-kpi-body { display: flex; flex-direction: column; min-width: 0; }
.dx-kpi-label { display: flex; align-items: center; gap: .4rem; font-size: .74rem; font-weight: 600; color: #b9cde3; }
.dx-kpi-value { font-size: 1.45rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.2; font-variant-numeric: tabular-nums; white-space: nowrap; }
.dx-kpi-value small { font-size: .75rem; font-weight: 600; color: #b9cde3; }
.dx-kpi-sub { font-size: .72rem; color: #a9c0d8; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dx-kpi-sub .up { color: #6ee7b7; } .dx-kpi-sub .down { color: #fda4af; }
.dx-trend { display: inline-flex; align-items: center; gap: .1rem; padding: .05rem .4rem; border-radius: 999px; font-size: .68rem; font-weight: 700; }
.dx-trend.is-up { background: rgba(110, 231, 183, .18); color: #6ee7b7; }
.dx-trend.is-down { background: rgba(253, 164, 175, .18); color: #fda4af; }

/* Grille des cartes */
.dx-grid { display: grid; gap: 1rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .dx-grid { grid-template-columns: 1fr 1fr; } .dx-chart { grid-column: 1 / -1; } }
@media (min-width: 1200px) { .dx-grid { grid-template-columns: minmax(0, 1.5fr) minmax(0, 1fr) minmax(0, 1.05fr); } .dx-chart { grid-column: auto; } }
.dx-side { display: flex; flex-direction: column; gap: 1rem; min-width: 0; }
.dx-card { position: relative; display: flex; flex-direction: column; min-width: 0; padding: 1rem 1.1rem; border-radius: 18px; background: #fff;
    border: 1px solid #e8edf4; box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 12px 32px -18px rgba(15, 23, 42, .18); }
.dx-card-head { display: flex; justify-content: space-between; align-items: flex-start; gap: .5rem; margin-bottom: .7rem; }
.dx-card-title { font-size: .95rem; font-weight: 750; color: var(--dx-ink); margin: 0; letter-spacing: -.01em; }
.dx-card-sub { display: block; font-size: .74rem; color: var(--dx-soft); }
.dx-pill { padding: .25rem .65rem; border-radius: 999px; background: #eff6ff; color: #1d4ed8; font-size: .74rem; font-weight: 700; white-space: nowrap; }

/* Graphique */
.dx-chart-wrap { flex: 1; display: flex; align-items: center; min-height: 0; }
.dx-chart-wrap svg { width: 100%; height: auto; max-height: 230px; overflow: visible; }
.dx-grid-line { stroke: #eef2f7; stroke-width: 1; stroke-dasharray: 3 4; }
.dx-axis { stroke: #dbe3ee; stroke-width: 1; }
.dx-hit { fill: transparent; }
.dx-track { fill: #f4f7fb; }
.dx-bar { fill: url(#dxBarSoft); transition: fill .2s; }
.dx-bar-group:hover .dx-bar, .dx-bar-group.is-current .dx-bar { fill: url(#dxBar); }
.dx-bar-group.is-current .dx-bar { filter: drop-shadow(0 6px 10px rgba(37, 99, 235, .35)); }
.dx-value { font-size: 11px; font-weight: 700; fill: #334155; }
.dx-bar-group.is-current .dx-value { fill: var(--dx-blue); }
.dx-month { font-size: 11px; fill: #64748b; font-weight: 600; }
.dx-bar-group.is-current .dx-month { fill: var(--dx-ink); }
.dx-mini { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .5rem; margin-top: .75rem; }
@media (max-width: 575.98px) { .dx-mini { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.dx-mini a { display: grid; grid-template-columns: auto 1fr; grid-template-rows: auto auto; column-gap: .45rem; align-items: center; padding: .45rem .5rem;
    border-radius: 12px; background: #f8fafc; text-decoration: none; color: var(--dx-ink); transition: background .2s; }
.dx-mini a:hover { background: #eef4ff; color: var(--dx-ink); }
.dx-mini i { grid-row: 1 / 3; width: 1.9rem; height: 1.9rem; border-radius: 9px; display: grid; place-items: center; background: #fff; color: var(--dx-blue); box-shadow: 0 2px 6px rgba(15, 23, 42, .06); }
.dx-mini b { font-size: 1rem; font-variant-numeric: tabular-nums; line-height: 1.1; }
.dx-mini span { font-size: .66rem; color: var(--dx-soft); line-height: 1.15; }

/* Anneau de répartition du coût */
.dx-donut { position: relative; width: min(190px, 100%); aspect-ratio: 1; margin: .2rem auto .9rem; }
.dx-donut svg { width: 100%; height: 100%; }
.dx-donut-track { fill: none; stroke: #f1f5f9; stroke-width: 5.2; }
.dx-donut-seg { fill: none; stroke-width: 5.2; stroke-linecap: butt; transition: stroke-width .2s; }
.dx-donut-seg:hover { stroke-width: 6.4; }
.dx-donut-center { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; }
.dx-donut-center span { font-size: .7rem; color: var(--dx-soft); font-weight: 600; }
.dx-donut-center strong { font-size: 1.5rem; font-weight: 800; color: var(--dx-ink); letter-spacing: -.02em; }
.dx-donut-center small { font-size: .7rem; color: var(--dx-soft); }
.seg-1 { stroke: #2563eb; } .seg-2 { stroke: #14b8a6; } .seg-3 { stroke: #a78bfa; } .seg-4 { stroke: #f59e0b; } .seg-5 { stroke: #cbd5e1; }
.dx-legend { list-style: none; padding: 0; margin: 0; display: grid; gap: .35rem; }
.dx-legend li { display: flex; align-items: center; gap: .55rem; font-size: .8rem; color: #334155; }
.dx-legend li span { flex: 1; }
.dx-legend li b { font-variant-numeric: tabular-nums; color: var(--dx-ink); }
.dx-legend i { width: .7rem; height: .7rem; border-radius: 4px; }
.dx-legend i.seg-1 { background: #2563eb; } .dx-legend i.seg-2 { background: #14b8a6; } .dx-legend i.seg-3 { background: #a78bfa; }
.dx-legend i.seg-4 { background: #f59e0b; } .dx-legend i.seg-5 { background: #cbd5e1; }
.dx-empty { flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .5rem; text-align: center; color: var(--dx-soft); font-size: .82rem; padding: 1rem; }
.dx-empty i { font-size: 2rem; color: #cbd5e1; }

/* Paie du mois */
.dx-pay { text-decoration: none; color: inherit; transition: transform .2s, box-shadow .2s; }
.dx-pay:hover { color: inherit; transform: translateY(-2px); box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 20px 40px -20px rgba(37, 99, 235, .35); }
.dx-go { width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; background: #eff6ff; color: var(--dx-blue); transition: transform .2s, background .2s, color .2s; }
.dx-pay:hover .dx-go { background: var(--dx-blue); color: #fff; transform: rotate(45deg); }
.dx-rings { display: grid; grid-template-columns: 1fr 1fr; gap: .6rem; }
.dx-ring { position: relative; display: flex; align-items: center; gap: .6rem; padding: .55rem .6rem; border-radius: 14px; background: linear-gradient(135deg, #f8fafc, #eff6ff); }
.dx-ring.is-ok { background: linear-gradient(135deg, #f8fafc, #ecfdf5); }
.dx-ring svg { width: 3.3rem; height: 3.3rem; flex-shrink: 0; transform: rotate(-90deg); }
.dx-ring-track { fill: none; stroke: #e2e8f0; stroke-width: 4; }
.dx-ring-value { fill: none; stroke: var(--dx-blue); stroke-width: 4; stroke-linecap: round; }
.dx-ring.is-ok .dx-ring-value { stroke: #10b981; }
.dx-ring-pct { position: absolute; left: .6rem; top: 50%; width: 3.3rem; height: 3.3rem; transform: translateY(-50%); display: flex; align-items: center; justify-content: center; }
.dx-ring-pct > span { font-size: .78rem; font-weight: 800; color: var(--dx-ink); font-variant-numeric: tabular-nums; white-space: nowrap; }
.dx-ring-pct small { font-size: .58rem; font-weight: 700; margin-left: 1px; }
.dx-ring-label { display: flex; flex-direction: column; font-size: .72rem; color: var(--dx-soft); line-height: 1.25; }
.dx-ring-label b { font-size: .95rem; color: var(--dx-ink); font-variant-numeric: tabular-nums; }

/* À traiter */
.dx-todo { flex: 1; }
.dx-ok { width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; background: #dcfce7; color: #16a34a; font-size: 1.1rem; }
.dx-todo-list { display: grid; gap: .3rem; }
.dx-todo-item { display: flex; align-items: center; gap: .6rem; padding: .42rem .55rem; border-radius: 11px; text-decoration: none; color: #334155; font-size: .82rem; transition: background .15s; }
.dx-todo-item:hover { background: #f1f5f9; color: var(--dx-ink); }
.dx-todo-item i { width: 1.8rem; height: 1.8rem; border-radius: 9px; display: grid; place-items: center; background: #f1f5f9; color: #94a3b8; flex-shrink: 0; }
.dx-todo-item span { flex: 1; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.dx-todo-item b { min-width: 1.7rem; padding: .05rem .45rem; border-radius: 999px; text-align: center; font-size: .74rem; background: #f1f5f9; color: #94a3b8; }
.dx-todo-item.has-items { color: var(--dx-ink); font-weight: 600; }
.dx-todo-item.has-items i { background: #fff7ed; color: #ea580c; }
.dx-todo-item.has-items b { background: linear-gradient(135deg, #f97316, #ef4444); color: #fff; box-shadow: 0 4px 10px -4px rgba(239, 68, 68, .6); }

/* Apparition douce des cartes */
@media (prefers-reduced-motion: no-preference) {
    .dx-hero, .dx-card { animation: dx-rise .5s cubic-bezier(.2, .8, .2, 1) both; }
    .dx-grid > :nth-child(1) { animation-delay: .05s; } .dx-grid > :nth-child(2) { animation-delay: .1s; }
    .dx-side > :nth-child(1) { animation-delay: .15s; } .dx-side > :nth-child(2) { animation-delay: .2s; }
    .dx-ring-value, .dx-donut-seg { animation: dx-draw 1s cubic-bezier(.2, .8, .2, 1) both .2s; }
}
@keyframes dx-rise { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
@keyframes dx-draw { from { stroke-dasharray: 0 100; } }

/* =====================================================================
   Super Admin > Paiements : liste des clients + échéancier du client choisi
   ===================================================================== */
.pay-layout { display: grid; gap: 1rem; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 992px) { .pay-layout { grid-template-columns: 300px minmax(0, 1fr); } }
.pay-clients { display: flex; flex-direction: column; overflow: hidden; }
@media (min-width: 992px) { .pay-clients { position: sticky; top: .75rem; max-height: calc(100vh - 10rem); } }
.pay-clients-search { padding: .7rem; border-bottom: 1px solid var(--rh-border); }
.pay-client-list { flex: 1; overflow-y: auto; scrollbar-width: thin; max-height: 50vh; }
@media (min-width: 992px) { .pay-client-list { max-height: none; } }
.pay-client { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem .65rem; padding: .6rem .8rem; text-decoration: none; color: var(--rh-text); border-bottom: 1px solid #f1f3f7; }
.pay-client:hover { background: #f6f8fc; color: var(--rh-text); }
.pay-client.active { background: var(--rh-primary-soft); box-shadow: inset 3px 0 0 var(--rh-primary); }
.pay-client[hidden] { display: none; }
.pay-client-all { border-bottom: 1px solid var(--rh-border); }
.pay-avatar { width: 2.2rem; height: 2.2rem; border-radius: 11px; display: grid; place-items: center; flex-shrink: 0; font-weight: 800; font-size: .78rem;
    background: #eef2ff; color: #4338ca; }
.pay-avatar.is-ok { background: #dcfce7; color: #15803d; }
.pay-avatar.is-late { background: #fee2e2; color: #b91c1c; }
.pay-avatar.is-empty { background: #f1f5f9; color: #64748b; }
.pay-client-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.pay-client-name { font-weight: 650; font-size: .86rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pay-client-meta { font-size: .72rem; color: var(--rh-muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.pay-client-bar { flex-basis: 100%; padding-left: 2.85rem; }
.pay-client-bar progress { width: 100%; height: 4px; border: 0; border-radius: 999px; overflow: hidden; background: #e9edf3; -webkit-appearance: none; appearance: none; display: block; }
.pay-client-bar progress::-webkit-progress-bar { background: #e9edf3; }
.pay-client-bar progress::-webkit-progress-value { background: #16a34a; border-radius: 999px; }
.pay-client-bar progress::-moz-progress-bar { background: #16a34a; border-radius: 999px; }
.pay-inline .form-select { min-width: 7.4rem; padding-right: 1.9rem; }
.pay-inline input[type="date"] { min-width: 8.6rem; }
.pay-actions { display: inline-flex; align-items: center; gap: .3rem; }
.pay-inline .form-control[name="Payment.Reference"] { max-width: 8rem; }
/* Formulaires compacts : garder la place de la loupe et de la flèche des listes */
body.app .search-field .form-control, body.app .table-search input { padding-left: 2rem; }
body.app .form-select { padding-right: 2.1rem; }
body.app .form-select-sm { padding-right: 1.9rem; }

/* =====================================================================
   Pointage mensuel (saisie manuelle et pointage final) : ligne essentielle + détail repliable
   ===================================================================== */
.ts-wrap { border: 1px solid #e8edf4; border-radius: 14px; }
.ts-table { --ts-line: #eef2f7; font-size: .86rem; }
.ts-table > thead th { background: #f8fafc; color: #64748b; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap;
    border-bottom: 1px solid #e8edf4; padding: .65rem .75rem; }
.ts-table > tbody > tr > td { border-bottom: 1px solid var(--ts-line); padding: .55rem .75rem; }
.ts-row:hover > td { background: #fafcff; }
.ts-row.is-open > td { background: #f5f9ff; border-bottom-color: transparent; }
.ts-row.is-validated > td { background: #f6fdf8; }
.ts-who { display: flex; align-items: center; gap: .6rem; min-width: 13rem; }
.ts-avatar { width: 2.1rem; height: 2.1rem; border-radius: 10px; display: grid; place-items: center; flex-shrink: 0; font-weight: 800; font-size: .85rem;
    background: linear-gradient(135deg, #e0ecff, #eef2ff); color: #3b5bdb; }
.ts-name { display: block; font-weight: 650; color: #0f172a; }
.ts-meta { display: block; font-size: .72rem; color: #64748b; }
.ts-qty { display: flex; align-items: center; gap: .45rem; white-space: nowrap; }
.ts-qty input { width: 5.2rem; text-align: right; font-weight: 650; }
.ts-qty span { font-size: .74rem; color: #64748b; }
.ts-days { margin-left: .3rem; padding: .05rem .4rem; border-radius: 999px; background: #fff7ed; color: #c2410c; font-weight: 700; font-size: .72rem; }
.ts-unit { font-size: .72rem; color: #94a3b8; }
.ts-money { font-variant-numeric: tabular-nums; color: #334155; }
.ts-net { font-weight: 700; color: #0f172a; }
.ts-badge { display: inline-flex; align-items: center; gap: .25rem; padding: .12rem .55rem; border-radius: 999px; font-size: .72rem; font-weight: 650;
    background: #f1f5f9; color: #64748b; }
.ts-badge.is-ok { background: #dcfce7; color: #15803d; }
.ts-badge.is-draft { background: #e0ecff; color: #1d4ed8; }
.ts-badge.is-hs { background: #fef3c7; color: #b45309; margin-left: .25rem; }
.ts-edit { width: 2.1rem; height: 2.1rem; border-radius: 10px; border: 1px solid #dbe3ee; background: #fff; color: #475569; display: inline-grid; place-items: center;
    transition: background .15s, color .15s, border-color .15s, transform .15s; }
.ts-edit:hover { border-color: var(--rh-primary); color: var(--rh-primary); transform: translateY(-1px); }
.ts-edit[aria-expanded="true"] { background: var(--rh-primary); border-color: var(--rh-primary); color: #fff; }
.ts-detail > td { background: #f5f9ff; padding: .2rem .75rem .9rem !important; }
.ts-fields { display: grid; grid-template-columns: repeat(auto-fill, minmax(8.5rem, 1fr)); gap: .55rem .7rem; padding: .75rem .8rem; border-radius: 12px;
    background: #fff; border: 1px solid #dfe8f5; box-shadow: 0 10px 24px -18px rgba(15, 23, 42, .35); }
.ts-fields label { display: flex; flex-direction: column; gap: .2rem; margin: 0; }
.ts-fields label > span { font-size: .7rem; font-weight: 700; color: #64748b; text-transform: uppercase; letter-spacing: .03em; }
.ts-fields input { text-align: right; }
.ts-fields .ts-notes { grid-column: span 2; }
.ts-fields .ts-notes input { text-align: left; }
.ts-ro { display: flex; align-items: center; min-height: 1.9rem; padding: 0 .55rem; border-radius: 8px; background: #f1f5f9; color: #334155; font-weight: 650; font-size: .84rem; }
@media (prefers-reduced-motion: no-preference) { .ts-detail:not([hidden]) .ts-fields { animation: dx-rise .25s ease both; } }

/* =====================================================================
   Gestion des salariés : tableau moderne, sélection et suppression groupée
   ===================================================================== */
.emp-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: flex-end; gap: .75rem; margin-bottom: 1rem; }
.emp-quota { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; font-size: .84rem; color: #64748b; }
.emp-quota b { color: #0f172a; }
.emp-quota-bar { width: 120px; height: 6px; border: 0; border-radius: 999px; overflow: hidden; background: #e2e8f0; -webkit-appearance: none; appearance: none; }
.emp-quota-bar::-webkit-progress-bar { background: #e2e8f0; }
.emp-quota-bar::-webkit-progress-value { background: linear-gradient(90deg, #14b8a6, #2563eb); border-radius: 999px; }
.emp-quota-bar::-moz-progress-bar { background: linear-gradient(90deg, #14b8a6, #2563eb); border-radius: 999px; }
.emp-quota-bar.is-full::-webkit-progress-value { background: #f59e0b; }
.emp-quota-bar.is-full::-moz-progress-bar { background: #f59e0b; }
.emp-btn { border: 1px solid #e2e8f0; background: #fff; font-weight: 600; font-size: .86rem; border-radius: 11px; }
.emp-btn:hover { border-color: var(--rh-primary); color: var(--rh-primary); background: #fff; }
.emp-btn-primary { border-radius: 11px; font-weight: 650; font-size: .86rem; box-shadow: 0 10px 22px -12px rgba(37, 99, 235, .8); }

.emp-card { background: #fff; border: 1px solid #e8edf4; border-radius: 18px; box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 18px 40px -26px rgba(15, 23, 42, .25); overflow: hidden; }
.emp-filters { display: flex; flex-wrap: wrap; align-items: center; gap: .6rem; padding: .9rem 1rem; border-bottom: 1px solid #eef2f7; background: linear-gradient(180deg, #fbfcfe, #fff); }
.emp-search { flex: 1 1 260px; }
.emp-search .form-control { border-radius: 11px; background: #f8fafc; border-color: #e2e8f0; }
.emp-search .form-control:focus { background: #fff; }
.emp-select { width: auto; min-width: 11rem; border-radius: 11px; background-color: #f8fafc; border-color: #e2e8f0; }
.emp-segments { display: inline-flex; padding: 3px; border-radius: 11px; background: #f1f5f9; }
.emp-segments label { padding: .3rem .8rem; border-radius: 8px; font-size: .82rem; font-weight: 650; color: #64748b; cursor: pointer; margin: 0; transition: background .15s, color .15s; }
.emp-segments .btn-check:checked + label { background: #fff; color: #0f172a; box-shadow: 0 1px 3px rgba(15, 23, 42, .12); }
.emp-segments .btn-check:focus-visible + label { outline: 2px solid var(--rh-primary); }
.emp-go { border-radius: 11px; font-size: .86rem; font-weight: 650; }

.emp-selbar { position: sticky; top: 0; z-index: 4; display: flex; align-items: center; gap: .6rem; padding: .55rem 1rem; font-size: .86rem;
    background: linear-gradient(90deg, #1e3a8a, #2563eb); color: #fff; }
.emp-selbar .btn-link { color: #dbeafe; text-decoration: none; }
.emp-selbar .btn-link:hover { color: #fff; }
.emp-table-wrap { border: 0; }
.emp-table { font-size: .86rem; }
.emp-table > thead th { background: #f8fafc; color: #64748b; font-size: .72rem; font-weight: 700; text-transform: uppercase; letter-spacing: .04em; white-space: nowrap;
    padding: .7rem .75rem; border-bottom: 1px solid #e8edf4; }
.emp-table > tbody > tr > td { padding: .6rem .75rem; border-bottom: 1px solid #f1f5f9; }
.emp-table > tbody > tr { transition: background .12s; }
.emp-table > tbody > tr:hover > td { background: #f8fbff; }
.emp-table > tbody > tr.is-selected > td { background: #eef4ff; }
.emp-table > tbody > tr.is-gone { opacity: .62; }
.emp-check { width: 2.6rem; text-align: center; }
.emp-check .form-check-input { margin: 0; cursor: pointer; }
.emp-lock { color: #cbd5e1; cursor: help; }
.emp-mat { display: inline-block; min-width: 2.4rem; padding: .1rem .45rem; border-radius: 7px; background: #f1f5f9; color: #475569; font-weight: 700; font-size: .78rem;
    text-align: center; font-variant-numeric: tabular-nums; }
.emp-who { display: flex; align-items: center; gap: .65rem; text-decoration: none; color: inherit; min-width: 13rem; }
.emp-who:hover .emp-name { color: var(--rh-primary); }
.emp-avatar { width: 2.3rem; height: 2.3rem; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; font-weight: 800; font-size: .8rem; color: #fff; }
.emp-avatar.hue-0 { background: linear-gradient(135deg, #60a5fa, #2563eb); }
.emp-avatar.hue-1 { background: linear-gradient(135deg, #34d399, #0d9488); }
.emp-avatar.hue-2 { background: linear-gradient(135deg, #a78bfa, #6d28d9); }
.emp-avatar.hue-3 { background: linear-gradient(135deg, #fbbf24, #ea580c); }
.emp-avatar.hue-4 { background: linear-gradient(135deg, #f472b6, #db2777); }
.emp-avatar.hue-5 { background: linear-gradient(135deg, #38bdf8, #0e7490); }
.emp-who-text { display: flex; flex-direction: column; min-width: 0; }
.emp-name { font-weight: 650; color: #0f172a; transition: color .15s; }
.emp-app { color: #14b8a6; font-size: .8rem; margin-left: .2rem; }
.emp-sub { font-size: .74rem; color: #94a3b8; }
.emp-mono { font-variant-numeric: tabular-nums; color: #475569; }
.emp-dept { display: inline-block; padding: .08rem .5rem; border-radius: 999px; background: #eef2ff; color: #4338ca; font-size: .74rem; font-weight: 650; }
.emp-type { display: inline-block; padding: .12rem .55rem; border-radius: 7px; font-size: .74rem; font-weight: 700; }
.emp-type.is-monthly { background: #e0f2fe; color: #0369a1; }
.emp-type.is-daily { background: #dcfce7; color: #15803d; }
.emp-type.is-hourly { background: #fef3c7; color: #b45309; }
.emp-type.is-unit { background: #fce7f3; color: #be185d; }
.emp-salary { font-weight: 700; color: #0f172a; font-variant-numeric: tabular-nums; }
.emp-status { display: inline-flex; align-items: center; gap: .35rem; font-size: .78rem; font-weight: 650; white-space: nowrap; }
.emp-status i { width: .5rem; height: .5rem; border-radius: 50%; }
.emp-status.is-active { color: #15803d; } .emp-status.is-active i { background: #22c55e; box-shadow: 0 0 0 3px rgba(34, 197, 94, .18); }
.emp-status.is-leaving { color: #b45309; } .emp-status.is-leaving i { background: #f59e0b; box-shadow: 0 0 0 3px rgba(245, 158, 11, .18); }
.emp-status.is-gone { color: #64748b; } .emp-status.is-gone i { background: #94a3b8; }
.emp-action { width: 2rem; height: 2rem; border-radius: 50%; display: inline-grid; place-items: center; color: #94a3b8; text-decoration: none; transition: background .15s, color .15s; }
.emp-table tr:hover .emp-action { background: #e0ecff; color: var(--rh-primary); }
.emp-foot { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem 1.25rem; padding: .7rem 1rem; border-top: 1px solid #eef2f7; font-size: .76rem; color: #94a3b8; background: #fbfcfe; }

/* Gestion des salariés : nom sans soulignement ; le tableau défile dans son cadre (en-têtes, filtres et boutons restent visibles) */
.emp-who, .emp-who:hover, .emp-who:focus, .emp-who * { text-decoration: none !important; }
@media (min-width: 992px) {
    .emp-table-wrap { max-height: calc(100vh - 17rem); overflow: auto; scrollbar-width: thin; }
    .emp-table-wrap > .emp-table > thead th { position: sticky; top: 0; z-index: 3; box-shadow: inset 0 -1px 0 #e8edf4; }
}

/* Bulletins : lien vers la fiche du salarié dans la liste et dans l'en-tête */
.payslip-row { position: relative; display: flex; align-items: stretch; border-bottom: 1px solid #f1f3f7; }
.payslip-row .payslip-item { flex: 1; min-width: 0; border-bottom: 0; padding-right: .3rem; }
.payslip-row.active { background: var(--rh-primary-soft); box-shadow: inset 3px 0 0 var(--rh-primary); }
.payslip-row.active .payslip-item { background: transparent; box-shadow: none; }
.payslip-fiche { display: grid; place-items: center; width: 2rem; flex-shrink: 0; color: #b6c0cf; text-decoration: none; font-size: .9rem; transition: color .15s, background .15s; }
.payslip-row:hover .payslip-fiche, .payslip-row.active .payslip-fiche { color: var(--rh-primary); }
.payslip-fiche:hover { background: #e0ecff; color: var(--rh-primary); }
.payslip-fiche-link { margin-left: .5rem; padding: .12rem .55rem; border-radius: 999px; background: #eef4ff; color: var(--rh-primary); font-size: .74rem; font-weight: 650;
    text-decoration: none; vertical-align: middle; white-space: nowrap; }
.payslip-fiche-link:hover { background: var(--rh-primary); color: #fff; }

/* =====================================================================
   Comptes groupe : espace « Mes sociétés », sélecteur de société, Super Admin
   ===================================================================== */
body.group-space { min-height: 100vh; background: #f3f6fb; color: #0f172a; }
.grp-top { position: sticky; top: 0; z-index: 20; display: flex; justify-content: space-between; align-items: center; gap: 1rem; padding: .7rem 1.5rem;
    background: rgba(255, 255, 255, .85); backdrop-filter: blur(10px); border-bottom: 1px solid #e6ebf2; }
.grp-brand img { height: 34px; }
.grp-top-actions { display: flex; align-items: center; gap: .75rem; }
.grp-back { display: inline-flex; align-items: center; gap: .4rem; padding: .4rem .85rem; border-radius: 999px; font-size: .84rem; font-weight: 650;
    color: var(--rh-primary); background: #eef4ff; text-decoration: none; }
.grp-back:hover { background: var(--rh-primary); color: #fff; }
.grp-user { display: flex; align-items: center; gap: .6rem; padding: .3rem .6rem .3rem .3rem; border-radius: 999px; border: 1px solid #e2e8f0; background: #fff; }
.grp-user-avatar { width: 2.1rem; height: 2.1rem; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .8rem; color: #fff;
    background: linear-gradient(135deg, #14b8a6, #2563eb); }
.grp-user-text { display: flex; flex-direction: column; text-align: left; line-height: 1.15; font-size: .84rem; font-weight: 650; }
.grp-user-text small { font-weight: 500; color: #64748b; font-size: .72rem; }
@media (max-width: 575.98px) { .grp-user-text { display: none; } }
.grp-main { max-width: 1320px; margin: 0 auto; padding: 1.5rem 1.25rem 3rem; }

.grp-hero { position: relative; overflow: hidden; display: grid; gap: 1.25rem; padding: 1.6rem 1.75rem; border-radius: 22px; color: #fff; margin-bottom: 1.25rem;
    background: radial-gradient(600px 260px at 95% -30%, rgba(56, 189, 248, .45), transparent 60%),
                radial-gradient(520px 260px at -5% 130%, rgba(20, 184, 166, .38), transparent 60%),
                linear-gradient(125deg, #071d38 0%, #0b2a4f 45%, #0f4f86 85%, #1279b0 100%);
    box-shadow: 0 22px 50px -20px rgba(11, 42, 79, .55); }
@media (min-width: 992px) { .grp-hero { grid-template-columns: minmax(0, 1fr) minmax(0, 1.25fr); align-items: center; } }
.grp-eyebrow { display: inline-flex; align-items: center; gap: .4rem; font-size: .78rem; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: #9ff0e2; }
.grp-title { font-size: clamp(1.5rem, 2.4vw, 2.1rem); font-weight: 800; letter-spacing: -.02em; margin: .3rem 0 .4rem; color: #fff; }
.grp-sub { margin: 0; color: #c6d6ea; font-size: .92rem; max-width: 34rem; }
.grp-tiles { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .65rem; }
@media (min-width: 768px) { .grp-tiles { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.grp-tile { display: flex; flex-direction: column; gap: .2rem; padding: .8rem .95rem; border-radius: 15px; background: rgba(255, 255, 255, .09);
    border: 1px solid rgba(255, 255, 255, .15); backdrop-filter: blur(8px); }
.grp-tile-label { font-size: .72rem; font-weight: 650; color: #b9cde3; }
.grp-tile-value { font-size: 1.45rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.1; font-variant-numeric: tabular-nums; white-space: nowrap; }
.grp-tile-value small { font-size: .78rem; font-weight: 600; color: #b9cde3; }
.grp-meter { width: 100%; height: 5px; border: 0; border-radius: 999px; overflow: hidden; margin-top: .25rem; background: rgba(255, 255, 255, .18); -webkit-appearance: none; appearance: none; }
.grp-meter::-webkit-progress-bar { background: rgba(255, 255, 255, .18); }
.grp-meter::-webkit-progress-value { background: #6ee7d3; border-radius: 999px; }
.grp-meter::-moz-progress-bar { background: #6ee7d3; border-radius: 999px; }
.grp-meter.is-full::-webkit-progress-value { background: #fbbf24; }
.grp-meter.is-full::-moz-progress-bar { background: #fbbf24; }

.grp-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: .75rem; margin-bottom: 1rem; }
.grp-search { flex: 0 1 380px; }
.grp-search .form-control { border-radius: 12px; padding-left: 2rem; background: #fff; }
.grp-end { font-size: .82rem; color: #64748b; display: inline-flex; gap: .4rem; align-items: center; }

.grp-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(290px, 1fr)); }
.grp-card { position: relative; display: flex; flex-direction: column; gap: .8rem; padding: 1.05rem 1.1rem; border-radius: 18px; background: #fff; border: 1px solid #e6ebf2;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 14px 34px -24px rgba(15, 23, 42, .3); transition: transform .2s, box-shadow .2s, border-color .2s; margin: 0; }
.grp-card[hidden] { display: none; }
form.grp-card:hover { transform: translateY(-3px); border-color: #c9d8f5; box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 22px 44px -22px rgba(37, 99, 235, .4); }
.grp-card.is-current { border-color: #93b4f5; box-shadow: 0 0 0 3px rgba(37, 99, 235, .12), 0 14px 34px -24px rgba(15, 23, 42, .3); }
.grp-card.is-new { border-color: #5eead4; box-shadow: 0 0 0 3px rgba(20, 184, 166, .15), 0 14px 34px -24px rgba(15, 23, 42, .3); }
.grp-card-head { display: flex; align-items: center; gap: .7rem; }
.grp-avatar { width: 2.7rem; height: 2.7rem; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; font-weight: 800; font-size: .9rem; color: #fff; }
.grp-avatar.hue-0 { background: linear-gradient(135deg, #60a5fa, #2563eb); } .grp-avatar.hue-1 { background: linear-gradient(135deg, #34d399, #0d9488); }
.grp-avatar.hue-2 { background: linear-gradient(135deg, #a78bfa, #6d28d9); } .grp-avatar.hue-3 { background: linear-gradient(135deg, #fbbf24, #ea580c); }
.grp-avatar.hue-4 { background: linear-gradient(135deg, #f472b6, #db2777); } .grp-avatar.hue-5 { background: linear-gradient(135deg, #38bdf8, #0e7490); }
.grp-card-who { display: flex; flex-direction: column; min-width: 0; flex: 1; }
.grp-card-name { font-weight: 750; font-size: 1rem; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-card-meta { font-size: .76rem; color: #64748b; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-badge { flex-shrink: 0; display: inline-flex; align-items: center; gap: .25rem; padding: .15rem .55rem; border-radius: 999px; font-size: .7rem; font-weight: 700; }
.grp-badge.is-current { background: #e0ecff; color: #1d4ed8; }
.grp-badge.is-new { background: #ccfbf1; color: #0f766e; }
.grp-card-body { display: flex; align-items: flex-end; justify-content: space-between; gap: .75rem; }
.grp-figures { display: flex; gap: 1.1rem; }
.grp-figures > div { display: flex; flex-direction: column; }
.grp-figures b { font-size: 1.15rem; font-weight: 800; color: #0f172a; font-variant-numeric: tabular-nums; }
.grp-figures span { font-size: .72rem; color: #64748b; }
/* Mini-histogramme : une série, passé en teinte atténuée, dernier mois en accent (couleurs vérifiées : contraste ≥ 3:1) */
.grp-spark { width: 104px; height: 36px; flex-shrink: 0; overflow: visible; }
.grp-spark-base { stroke: #e2e8f0; stroke-width: 1; }
.grp-spark-hit { fill: transparent; }
.grp-spark-bar path { fill: #6b8fe8; transition: fill .15s; }
.grp-spark-bar.is-last path { fill: #1d4ed8; }
.grp-spark-bar:hover path { fill: #1e40af; }
.grp-card-foot { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding-top: .7rem; border-top: 1px solid #eef2f7; margin-top: auto; }
.grp-progress { display: flex; align-items: center; gap: .5rem; font-size: .74rem; color: #64748b; min-width: 0; }
.grp-progress progress { width: 70px; height: 6px; border: 0; border-radius: 999px; overflow: hidden; background: #dbeafe; -webkit-appearance: none; appearance: none; flex-shrink: 0; }
.grp-progress progress::-webkit-progress-bar { background: #dbeafe; }
.grp-progress progress::-webkit-progress-value { background: #16a34a; border-radius: 999px; }
.grp-progress progress::-moz-progress-bar { background: #16a34a; border-radius: 999px; }
.grp-progress.is-empty { font-style: italic; }
.grp-open { display: inline-flex; align-items: center; gap: .35rem; padding: .42rem .9rem; border-radius: 11px; border: 0; font-size: .84rem; font-weight: 700; color: #fff;
    background: linear-gradient(135deg, #2563eb, #1d4ed8); box-shadow: 0 10px 20px -12px rgba(37, 99, 235, .9); transition: transform .15s; flex-shrink: 0; }
.grp-open:hover { transform: translateX(2px); }
.grp-open::after { content: ""; position: absolute; inset: 0; border-radius: 18px; }   /* toute la carte est cliquable */

.grp-add { border: 2px dashed #c9d6e8; background: rgba(255, 255, 255, .6); box-shadow: none; justify-content: center; }
.grp-add.is-locked { align-items: center; text-align: center; color: #64748b; }
.grp-add-toggle { display: flex; flex-direction: column; align-items: center; gap: .35rem; border: 0; background: transparent; padding: 1rem; color: inherit; width: 100%; }
.grp-add-toggle:hover .grp-add-icon { background: var(--rh-primary); color: #fff; transform: rotate(90deg); }
.grp-add-icon { width: 3rem; height: 3rem; border-radius: 50%; display: grid; place-items: center; font-size: 1.35rem; background: #e0ecff; color: var(--rh-primary); transition: transform .25s, background .2s, color .2s; }
.grp-add-title { font-weight: 750; font-size: 1rem; }
.grp-add-text { font-size: .78rem; color: #64748b; }
.grp-add-form { width: 100%; }
.grp-empty { text-align: center; color: #64748b; padding: 2.5rem 1rem; }
.grp-empty i { font-size: 2.4rem; color: #cbd5e1; }
@media (prefers-reduced-motion: no-preference) {
    .grp-hero, .grp-card { animation: dx-rise .45s cubic-bezier(.2, .8, .2, 1) both; }
    .grp-grid > :nth-child(2) { animation-delay: .04s; } .grp-grid > :nth-child(3) { animation-delay: .08s; } .grp-grid > :nth-child(n+4) { animation-delay: .12s; }
}

/* Sélecteur « Changer de société » dans la barre du haut */
.grp-switch-btn { display: flex; align-items: center; gap: .55rem; padding: .35rem .7rem; border-radius: 12px; border: 1px solid #dbe3ee; background: #fff; max-width: 280px; transition: border-color .15s, box-shadow .15s; }
.grp-switch-btn:hover, .grp-switch-btn[aria-expanded="true"] { border-color: var(--rh-primary); box-shadow: 0 6px 16px -10px rgba(37, 99, 235, .6); }
.grp-switch-btn > .bi-buildings { color: var(--rh-primary); font-size: 1.05rem; }
.grp-switch-text { display: flex; flex-direction: column; text-align: left; line-height: 1.1; min-width: 0; }
.grp-switch-text small { font-size: .66rem; color: #64748b; font-weight: 600; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-switch-text span { font-size: .84rem; font-weight: 700; color: #0f172a; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.grp-switch-icon { color: #94a3b8; font-size: .85rem; }
@media (max-width: 767.98px) { .grp-switch-text { display: none; } }
.grp-switch-menu { width: 290px; padding: .4rem 0; border-radius: 14px; border-color: #e2e8f0; box-shadow: 0 20px 44px rgba(15, 23, 42, .18); }
.grp-switch-head { display: flex; justify-content: space-between; padding: .3rem .9rem .5rem; font-weight: 750; font-size: .85rem; }
.grp-switch-head small { color: #64748b; font-weight: 650; }
.grp-switch-list { max-height: 320px; overflow-y: auto; scrollbar-width: thin; }
.grp-switch-list form[hidden] { display: none; }
.grp-switch-item { display: flex; align-items: center; gap: .6rem; width: 100%; padding: .45rem .9rem; border: 0; background: transparent; text-align: left; font-size: .86rem; }
.grp-switch-item:hover:not(:disabled) { background: #f1f5ff; }
.grp-switch-item.is-current { background: #eef4ff; color: #1d4ed8; opacity: 1; }
.grp-switch-dot { width: .5rem; height: .5rem; border-radius: 50%; background: #22c55e; flex-shrink: 0; }
.grp-switch-name { display: flex; flex-direction: column; flex: 1; min-width: 0; font-weight: 650; }
.grp-switch-name small { font-size: .7rem; color: #94a3b8; font-weight: 500; }
.grp-switch-all { display: flex; align-items: center; gap: .45rem; padding: .55rem .9rem .3rem; margin-top: .3rem; border-top: 1px solid #eef2f7; font-size: .84rem; font-weight: 650; text-decoration: none; }

/* Super Admin : type de compte */
.acct-kinds { display: grid; gap: .75rem; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); }
.acct-kind { display: flex; gap: .8rem; align-items: flex-start; padding: .9rem 1rem; border-radius: 14px; border: 2px solid #e2e8f0; background: #fff; cursor: pointer; margin: 0;
    transition: border-color .15s, box-shadow .15s, background .15s; }
.acct-kind strong { display: block; font-size: .95rem; }
.acct-kind small { color: #64748b; font-size: .8rem; }
.acct-kind-icon { width: 2.5rem; height: 2.5rem; border-radius: 12px; display: grid; place-items: center; flex-shrink: 0; font-size: 1.15rem; background: #f1f5f9; color: #475569; }
.btn-check:checked + .acct-kind { border-color: var(--rh-primary); background: #f5f8ff; box-shadow: 0 0 0 3px rgba(37, 99, 235, .12); }
.btn-check:checked + .acct-kind .acct-kind-icon { background: var(--rh-primary); color: #fff; }
.btn-check:focus-visible + .acct-kind { outline: 2px solid var(--rh-primary); outline-offset: 2px; }
.acct-badge { background: #ede9fe; color: #5b21b6; font-weight: 700; }
[data-show-if][hidden] { display: none !important; }
.grp-spark { position: relative; z-index: 1; }

/* Outils > Exporter : une carte par export */
.exp-grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fill, minmax(300px, 1fr)); }
.exp-card { display: flex; flex-direction: column; gap: .85rem; padding: 1.1rem 1.15rem; border-radius: 18px; background: #fff; border: 1px solid #e6ebf2;
    box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 14px 34px -26px rgba(15, 23, 42, .3); transition: border-color .2s, box-shadow .2s; }
.exp-card:hover { border-color: #c9d8f5; box-shadow: 0 1px 2px rgba(15, 23, 42, .04), 0 20px 40px -24px rgba(37, 99, 235, .35); }
.exp-head { display: flex; gap: .8rem; align-items: flex-start; }
.exp-icon { width: 2.7rem; height: 2.7rem; border-radius: 13px; display: grid; place-items: center; flex-shrink: 0; font-size: 1.2rem; color: #fff;
    background: linear-gradient(135deg, #14b8a6, #2563eb); }
.exp-card:nth-child(2) .exp-icon { background: linear-gradient(135deg, #38bdf8, #0e7490); }
.exp-card:nth-child(3) .exp-icon { background: linear-gradient(135deg, #fbbf24, #ea580c); }
.exp-card:nth-child(4) .exp-icon { background: linear-gradient(135deg, #a78bfa, #6d28d9); }
.exp-title { font-size: 1.02rem; font-weight: 750; margin: 0 0 .15rem; }
.exp-text { font-size: .8rem; color: #64748b; margin: 0; }
.exp-scope { display: flex; padding: 3px; border-radius: 11px; background: #f1f5f9; }
.exp-scope label { flex: 1; text-align: center; padding: .38rem .5rem; border-radius: 8px; font-size: .8rem; font-weight: 650; color: #64748b; cursor: pointer; margin: 0; }
.exp-scope .btn-check:checked + label { background: #fff; color: #0f172a; box-shadow: 0 1px 3px rgba(15, 23, 42, .12); }
.exp-options { display: grid; gap: .4rem; }
.exp-option { display: flex; align-items: center; gap: .5rem; font-size: .84rem; margin: 0; cursor: pointer; }
.exp-option .form-check-input { margin: 0; }
.exp-go { margin-top: auto; border-radius: 11px; font-weight: 650; }
.acct-kinds-sm .acct-kind { padding: .6rem .75rem; } .acct-kinds-sm .acct-kind-icon { width: 2.1rem; height: 2.1rem; font-size: 1rem; }

/* Espace groupe : actions sur une société (sauvegarde, suppression) */
.grp-menu { position: relative; z-index: 2; margin-left: auto; }
.grp-menu-btn { width: 2rem; height: 2rem; border-radius: 9px; border: 0; background: transparent; color: #94a3b8; display: grid; place-items: center; }
.grp-menu-btn:hover, .grp-menu-btn[aria-expanded="true"] { background: #f1f5f9; color: #0f172a; }
.grp-backup-all { border: 1px solid #e2e8f0; background: #fff; font-weight: 650; border-radius: 10px; }
.grp-del { border-radius: 18px; border: 0; box-shadow: 0 30px 70px rgba(15, 23, 42, .35); }
.grp-del-backup { display: flex; align-items: center; justify-content: space-between; gap: .75rem; padding: .8rem .9rem; border-radius: 12px; background: #eff6ff; border: 1px solid #bfdbfe; }
.grp-del-backup strong { display: block; font-size: .9rem; }
.grp-del-backup span { font-size: .78rem; color: #475569; }

/* =====================================================================
   Éditeur de documents (type traitement de texte) et formes des modèles
   ===================================================================== */
.rich-toolbar { display: flex; flex-wrap: wrap; align-items: center; gap: .3rem; padding: .4rem .5rem; border: 1px solid var(--rh-border, #e5e7eb);
    border-bottom: 0; border-radius: .6rem .6rem 0 0; background: #f8fafc; position: sticky; top: 0; z-index: 5; }
.rich-group { display: flex; align-items: center; gap: .15rem; }
.rich-toolbar .btn { padding: .2rem .45rem; border-radius: 7px; color: #334155; }
.rich-toolbar .btn:hover, .rich-toolbar .btn[aria-expanded="true"] { background: #e2e8f0; }
.rich-toolbar .rich-label { font-size: .8rem; font-weight: 600; }
.rich-toolbar .rich-font { width: 9.5rem; }
.rich-toolbar .rich-size { width: 5.4rem; }
.rich-sep { width: 1px; height: 1.4rem; background: #dbe3ee; margin: 0 .2rem; }
.rich-menu { min-width: 15rem; }
.rich-menu label.small input { width: 4.5rem; }
.rich-colors { display: grid; grid-template-columns: repeat(7, 1.6rem); gap: .3rem; padding: .5rem; min-width: 0; }
.rich-color { width: 1.6rem; height: 1.6rem; border-radius: 6px; border: 2px solid #fff; box-shadow: 0 0 0 1px #cbd5e1; }
.rich-color:hover { box-shadow: 0 0 0 2px var(--rh-primary); }
.swatch-000000 { background: #000000; } .swatch-1f3864 { background: #1f3864; } .swatch-1d4ed8 { background: #1d4ed8; }
.swatch-b91c1c { background: #b91c1c; } .swatch-15803d { background: #15803d; } .swatch-b45309 { background: #b45309; } .swatch-6b7280 { background: #6b7280; }

/* Formes des modèles : mêmes rendus dans l'éditeur, l'aperçu, le document généré et à l'impression */
.document-html table.doc-table { border-collapse: collapse; width: 100%; margin: .4rem 0 .7rem; }
.document-html table.doc-table td, .document-html table.doc-table th { border: 1px solid #1f2937; padding: .2rem .45rem; vertical-align: top; }
.document-html table.doc-plain { border-collapse: collapse; width: 100%; margin: .3rem 0 .6rem; }
.document-html table.doc-plain td, .document-html table.doc-plain th { border: 0; padding: .15rem .4rem; vertical-align: top; }
.rich-editor table.doc-plain td { outline: 1px dashed #cbd5e1; }   /* repère à l'écran seulement, pendant la saisie */
.document-html .doc-title-box { margin: .8rem auto 1rem; padding: .35rem 1rem; border: 1px solid #1f2937; background: #d9d9d9; text-align: center;
    font-family: Arial, sans-serif; font-size: 1.45rem; font-weight: 700; letter-spacing: .02em; }
.document-html .doc-band { margin: .5rem 0 .35rem; padding: .18rem .5rem; border: 1px solid #9ca3af; background: #e5e7eb; font-family: Arial, sans-serif;
    font-size: .86em; font-weight: 700; }
.document-html .doc-box { margin: .5rem 0; padding: .5rem .7rem; border: 1px solid #1f2937; }
.document-html .doc-cols { display: grid; grid-template-columns: 1fr 1fr; gap: .2rem 1.1rem; align-items: start; }
.document-html .doc-cols p { text-align: justify; }
.document-html .doc-article { break-inside: avoid; }
.document-html table.doc-sign { width: 100%; border-collapse: separate; border-spacing: .8rem 0; margin-top: .8rem; }
.document-html table.doc-sign td { width: 50%; height: 6.5rem; border: 1.5px solid #1f2937; vertical-align: top; padding: .4rem .6rem; }
.document-html .doc-pagebreak { height: 0; border-top: 1px dashed #94a3b8; margin: 1rem 0; }
.document-html .doc-small { font-size: .88em; }
@media print {
    .document-html .doc-pagebreak { border: 0; margin: 0; break-after: page; }
    .document-html .doc-title-box, .document-html .doc-band { -webkit-print-color-adjust: exact; print-color-adjust: exact; }
    .rich-editor table.doc-plain td { outline: 0; }
}

/* =====================================================================
   Site public v3 (maquette du 20/10/2026) : en-tête, accueil, bandeau des atouts
   ===================================================================== */
.pub-header-v3 { background: rgba(255, 255, 255, .96); }
.pub-header-v3 .navbar { padding: .65rem 0; }
.pub-brand-v3 { display: inline-flex; flex-direction: column; gap: .1rem; text-decoration: none; }
.pub-brand-v3 img { height: 46px; width: auto; }
.pub-brand-v3 span { font-size: .72rem; font-weight: 600; color: #52627a; letter-spacing: .01em; padding-left: .15rem; }
.pub-nav-v3 { gap: .6rem; }
.pub-nav-v3 .nav-link { position: relative; color: #1f2d4a; font-weight: 600; font-size: .98rem; padding: .5rem .55rem !important; }
.pub-nav-v3 .nav-link:hover, .pub-nav-v3 .nav-link.active { color: #0e7490; }
.pub-nav-v3 .nav-link.active::after { content: ""; position: absolute; left: .55rem; right: .55rem; bottom: -.15rem; height: 3px; border-radius: 3px;
    background: linear-gradient(90deg, #16c3a6, #1565c0); }
.pub-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .55rem; padding: .5rem 0; }
.pub-btn-download { display: inline-flex; align-items: center; gap: .45rem; padding: .62rem 1rem; border-radius: 999px; font-weight: 700; font-size: .9rem;
    color: #0e7490; background: #e6f7f5; border: 1px solid #b9ece4; }
.pub-btn-download:hover { background: #16c3a6; border-color: #16c3a6; color: #fff; }
.pub-btn-signin { display: inline-flex; align-items: center; gap: .45rem; padding: .62rem 1.15rem; border-radius: 999px; font-weight: 600; font-size: .9rem;
    color: #1f2d4a; background: #fff; border: 1.5px solid #d5dde8; }
.pub-btn-signin:hover { border-color: #1565c0; color: #1565c0; background: #fff; }
.pub-btn-cta { display: inline-flex; align-items: center; gap: .55rem; padding: .7rem 1.35rem; border-radius: 999px; font-weight: 700; font-size: .92rem; color: #fff;
    background: linear-gradient(100deg, #16c3a6 0%, #1590c8 55%, #1d3fa8 100%); border: 0; box-shadow: 0 12px 26px -12px rgba(21, 101, 192, .75);
    transition: transform .15s, box-shadow .15s; }
.pub-btn-cta:hover { color: #fff; transform: translateY(-1px); box-shadow: 0 16px 30px -12px rgba(21, 101, 192, .85); }
@media (max-width: 1199.98px) { .pub-actions { padding-top: .75rem; } .pub-nav-v3 { gap: 0; } }

.hero3 { position: relative; overflow: hidden; background: linear-gradient(180deg, #f4f9fd 0%, #eef6fc 60%, #ffffff 100%); }
.hero3::before { content: ""; position: absolute; right: -18%; top: -12%; width: 78%; height: 120%; border-radius: 50%;
    background: radial-gradient(closest-side, rgba(56, 152, 236, .16), rgba(56, 152, 236, .06) 70%, transparent); pointer-events: none; }
.hero3-inner { position: relative; max-width: 1440px; margin: 0 auto; display: grid; gap: 2rem; padding: 2.5rem 1.25rem 3.5rem; align-items: center; }
@media (min-width: 992px) { .hero3-inner { grid-template-columns: minmax(0, 1fr) minmax(0, 1.08fr); padding: 3rem 2.5rem 4.5rem 3.5rem; } }
.hero3-badge { display: inline-flex; align-items: center; gap: .55rem; padding: .35rem .95rem .35rem .4rem; border-radius: 999px; background: #e3f4fb;
    color: #12395f; font-size: .86rem; font-weight: 600; }
.hero3-badge-icon { width: 1.75rem; height: 1.75rem; border-radius: 50%; display: grid; place-items: center; color: #fff; background: linear-gradient(135deg, #16c3a6, #1565c0); }
.hero3-title { margin: 1.2rem 0 1.1rem; font-size: clamp(2.1rem, 3.5vw, 3.35rem); font-weight: 800; line-height: 1.08; letter-spacing: -.035em; color: #0f1e3d; }
.hero3-accent { background: linear-gradient(100deg, #16c3a6, #1590c8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero3-brand { position: relative; display: inline-block; color: #0f2a5c; }
.hero3-brand span { background: linear-gradient(100deg, #16c3a6, #1590c8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.hero3-brand::after { content: ""; position: absolute; left: 4%; right: 2%; bottom: -.32em; height: .38em; border-bottom: 4px solid #1590c8;
    border-radius: 0 0 60% 40% / 0 0 100% 100%; opacity: .85; }
.hero3-lead { max-width: 36rem; color: #3b4a63; font-size: clamp(1rem, 1.25vw, 1.12rem); line-height: 1.6; margin: 1.4rem 0 1.6rem; }
.hero3-features { list-style: none; padding: 0; margin: 0 0 1.9rem; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem 0; }
@media (min-width: 768px) { .hero3-features { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.hero3-features li { display: flex; flex-direction: column; gap: .2rem; padding: 0 1.1rem; border-left: 1px solid #dbe5ef; }
.hero3-features li:first-child { padding-left: 0; border-left: 0; }
@media (max-width: 767.98px) { .hero3-features li:nth-child(odd) { padding-left: 0; border-left: 0; } }
.hero3-ficon { width: 2.8rem; height: 2.8rem; border-radius: 12px; display: grid; place-items: center; margin-bottom: .55rem; font-size: 1.3rem; color: #1565c0;
    background: linear-gradient(135deg, #eaf4ff, #e2f7f4); box-shadow: 0 8px 18px -12px rgba(21, 101, 192, .55); }
.hero3-features strong { color: #12233f; font-size: .92rem; line-height: 1.25; }
.hero3-features small { color: #64748b; font-size: .78rem; line-height: 1.35; }
.hero3-cta { display: flex; flex-wrap: wrap; gap: .9rem; }
.hero3-btn-primary { display: inline-flex; align-items: center; gap: .6rem; padding: .95rem 1.6rem; border-radius: 16px; font-weight: 700; font-size: 1rem; color: #fff;
    background: linear-gradient(100deg, #16c3a6 0%, #1590c8 55%, #1d3fa8 100%); box-shadow: 0 16px 32px -14px rgba(21, 101, 192, .8); border: 0; transition: transform .15s; }
.hero3-btn-primary:hover { color: #fff; transform: translateY(-2px); }
.hero3-btn-ghost { display: inline-flex; align-items: center; gap: .7rem; padding: .7rem 1.5rem .7rem .7rem; border-radius: 16px; font-weight: 700; font-size: 1rem;
    color: #12233f; background: #fff; border: 1.5px solid #c9d8ec; transition: border-color .15s, transform .15s; }
.hero3-btn-ghost:hover { border-color: #1565c0; color: #1565c0; transform: translateY(-2px); }
.hero3-play { width: 2.2rem; height: 2.2rem; border-radius: 50%; display: grid; place-items: center; color: #fff; background: #12395f; }
.hero3-visual { position: relative; }
.hero3-visual img { width: 100%; height: auto; display: block; border-radius: 28px 0 0 28px;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 9%, #000 100%); mask-image: linear-gradient(90deg, transparent 0%, #000 9%, #000 100%); }
@media (min-width: 992px) { .hero3-visual { margin-right: -2.5rem; } }

.hero3-band { position: relative; color: #fff; background: linear-gradient(100deg, #0b2a4f 0%, #0f3b6e 55%, #135a92 100%); border-radius: 0 60px 0 0; }
.hero3-band-inner { max-width: 1440px; margin: 0 auto; display: grid; gap: 1.2rem; padding: 1.8rem 1.25rem; align-items: center; }
@media (min-width: 768px) { .hero3-band-inner { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (min-width: 1200px) { .hero3-band-inner { grid-template-columns: repeat(4, minmax(0, 1fr)) minmax(0, 1.05fr); padding: 1.9rem 3.5rem; } }
.hero3-perk { display: flex; gap: .9rem; align-items: center; padding-right: 1rem; }
@media (min-width: 1200px) { .hero3-perk + .hero3-perk { border-left: 1px solid rgba(255, 255, 255, .16); padding-left: 1.4rem; } }
.hero3-perk > span { width: 3.1rem; height: 3.1rem; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; font-size: 1.35rem;
    background: rgba(255, 255, 255, .1); border: 1px solid rgba(255, 255, 255, .22); }
.hero3-perk strong { display: block; font-size: .95rem; }
.hero3-perk small { color: #b8cbe0; font-size: .8rem; line-height: 1.4; }
.hero3-morocco { display: flex; flex-direction: column; align-items: center; text-align: center; gap: .2rem; padding: .4rem 1rem; }
.hero3-morocco strong { font-size: 1.05rem; }
.hero3-morocco small { color: #c8d8ea; font-size: .8rem; max-width: 17rem; }
.hero3-star { display: flex; align-items: center; gap: .5rem; width: 100%; max-width: 15rem; margin-top: .3rem; color: #fff; }
.hero3-star i:not(.bi) { flex: 1; height: 1px; background: rgba(255, 255, 255, .45); }
/* Image de l'accueil fondue dans le fond (bords gauche, haut et bas), collée au bord droit de l'écran */
.hero3-visual img { border-radius: 0;
    -webkit-mask-image: linear-gradient(90deg, transparent 0%, #000 12%), linear-gradient(180deg, transparent 0%, #000 7%, #000 90%, transparent 100%);
    -webkit-mask-composite: source-in;
    mask-image: linear-gradient(90deg, transparent 0%, #000 12%), linear-gradient(180deg, transparent 0%, #000 7%, #000 90%, transparent 100%);
    mask-composite: intersect; }
@media (min-width: 992px) { .hero3-visual { margin-right: -3.5rem; } }

/* Boutons « Se connecter » (en-tête et accueil) : aussi visibles que « Demander un abonnement », en bleu nuit plein (demande du 20/10/2026) */
.pub-actions { gap: .6rem; }
.pub-actions-sep { width: 1px; height: 1.8rem; background: #dbe3ee; margin: 0 .15rem; }
@media (max-width: 1199.98px) { .pub-actions-sep { display: none; } }
.pub-btn-download { padding: .55rem .9rem; font-size: .88rem; }
.pub-btn-signin { display: inline-flex; align-items: center; gap: .55rem; padding: .38rem 1.3rem .38rem .38rem; border-radius: 999px; border: 0;
    font-weight: 700; font-size: .92rem; color: #fff; background: linear-gradient(100deg, #0b2a4f 0%, #12437a 60%, #1565c0 100%);
    box-shadow: 0 12px 26px -12px rgba(11, 42, 79, .8); transition: transform .15s, box-shadow .15s, filter .15s; }
.pub-btn-signin:hover, .pub-btn-signin:focus-visible { color: #fff; transform: translateY(-1px); box-shadow: 0 16px 30px -12px rgba(11, 42, 79, .9); filter: brightness(1.08); }
.pub-btn-icon { width: 2rem; height: 2rem; border-radius: 50%; display: grid; place-items: center; font-size: .95rem; color: #0b2a4f; background: #fff;
    box-shadow: 0 4px 10px rgba(0, 0, 0, .2); }
.pub-btn-cta { padding: .78rem 1.4rem; }

.hero3-btn-signin { display: inline-flex; align-items: center; gap: .7rem; padding: .55rem 1.5rem .55rem .55rem; border-radius: 16px; border: 0;
    font-weight: 700; font-size: 1rem; color: #fff; background: linear-gradient(100deg, #0b2a4f 0%, #12437a 60%, #1565c0 100%);
    box-shadow: 0 16px 32px -14px rgba(11, 42, 79, .85); transition: transform .15s, box-shadow .15s, filter .15s; }
.hero3-btn-signin:hover, .hero3-btn-signin:focus-visible { color: #fff; transform: translateY(-2px); filter: brightness(1.08); }
.hero3-btn-signin .bi-arrow-right { transition: transform .15s; }
.hero3-btn-signin:hover .bi-arrow-right { transform: translateX(3px); }
.hero3-btn-icon { width: 2.4rem; height: 2.4rem; border-radius: 12px; display: grid; place-items: center; font-size: 1.1rem; color: #0b2a4f; background: #fff; }
/* Même hauteur que « Demander un abonnement » dans l en-tête */
.pub-btn-signin { padding: .32rem 1.25rem .32rem .32rem; border-radius: 999px !important; }
.pub-btn-icon { width: 1.85rem; height: 1.85rem; }

/* En-tête v3 (20/10/2026) : « Télécharger » (turquoise) et « Se connecter » (bleu), même style simple ; l'abonnement se demande depuis l'accueil */
.pub-btn-login2 { display: inline-flex; align-items: center; gap: .45rem; padding: .55rem 1rem; border-radius: 999px; font-weight: 700; font-size: .88rem;
    color: #1565c0; background: #e8f1fd; border: 1px solid #c4d9f5; transition: background .15s, border-color .15s, color .15s; }
.pub-btn-login2 .bi { font-size: 1.05rem; }
.pub-btn-login2:hover, .pub-btn-login2:focus-visible { color: #fff; background: #1565c0; border-color: #1565c0; }
/* Accueil : un seul bouton, aussi large que la rangée des quatre atouts */
.hero3-cta .hero3-btn-primary { width: 100%; justify-content: center; padding: 1.05rem 1.6rem; font-size: 1.05rem; }

/* « Se connecter » animé (20/10/2026) : bordure en dégradé turquoise → bleu qui ondule, pastille avec halo, remplissage au survol */
.pub-btn-login3 { position: relative; display: inline-flex; align-items: center; gap: .55rem; padding: .3rem 1.05rem .3rem .3rem; border-radius: 999px;
    font-weight: 700; font-size: .9rem; color: #12437a; border: 2px solid transparent; overflow: hidden; isolation: isolate;
    background: linear-gradient(#f3f8ff, #f3f8ff) padding-box,
                linear-gradient(110deg, #16c3a6, #1590c8, #1d3fa8, #1590c8, #16c3a6) border-box;
    background-size: 100% 100%, 300% 100%;
    box-shadow: 0 8px 20px -14px rgba(21, 101, 192, .7);
    transition: color .25s, box-shadow .25s, transform .2s; }
/* Remplissage en dégradé qui glisse de gauche à droite au survol */
.pub-btn-login3::before { content: ""; position: absolute; inset: 0; z-index: -1; border-radius: inherit;
    background: linear-gradient(100deg, #16c3a6 0%, #1590c8 55%, #1d3fa8 100%); transform: translateX(-101%); transition: transform .35s cubic-bezier(.2, .8, .2, 1); }
.pub-btn-login3:hover, .pub-btn-login3:focus-visible { color: #fff; transform: translateY(-1px); box-shadow: 0 14px 28px -12px rgba(21, 101, 192, .75); }
.pub-btn-login3:hover::before, .pub-btn-login3:focus-visible::before { transform: translateX(0); }
.login3-icon { position: relative; width: 1.9rem; height: 1.9rem; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0;
    font-size: .95rem; color: #fff; background: linear-gradient(135deg, #16c3a6, #1565c0); transition: background .25s, color .25s; }
.login3-icon::after { content: ""; position: absolute; inset: -4px; border-radius: 50%; border: 2px solid rgba(22, 195, 166, .55); opacity: 0; }
.pub-btn-login3:hover .login3-icon { background: #fff; color: #1565c0; }
.login3-arrow { width: 0; opacity: 0; margin-left: -.35rem; transition: width .25s, opacity .25s, margin .25s, transform .25s; }
.pub-btn-login3:hover .login3-arrow, .pub-btn-login3:focus-visible .login3-arrow { width: 1rem; opacity: 1; margin-left: 0; transform: translateX(2px); }
@media (prefers-reduced-motion: no-preference) {
    .pub-btn-login3 { animation: login3-flow 6s linear infinite; }
    .login3-icon::after { animation: login3-pulse 2.6s ease-out infinite; }
}
@keyframes login3-flow { from { background-position: 0 0, 0% 50%; } to { background-position: 0 0, 300% 50%; } }
@keyframes login3-pulse { 0% { transform: scale(.85); opacity: .9; } 70% { transform: scale(1.25); opacity: 0; } 100% { opacity: 0; } }

/* « Se connecter » en version sombre (21/10/2026) : fond bleu nuit, texte blanc, bordure en dégradé qui ondule */
.pub-btn-login3 { color: #fff;
    background: linear-gradient(120deg, #071d38 0%, #0b2a4f 55%, #103a6b 100%) padding-box,
                linear-gradient(110deg, #16c3a6, #38bdf8, #1d3fa8, #38bdf8, #16c3a6) border-box;
    background-size: 100% 100%, 300% 100%;
    box-shadow: 0 10px 24px -12px rgba(7, 29, 56, .85), inset 0 1px 0 rgba(255, 255, 255, .08); }
.pub-btn-login3 .login3-text { color: #fff; }
.pub-btn-login3 .login3-icon { background: linear-gradient(135deg, #16c3a6, #38bdf8); color: #071d38; }
.pub-btn-login3 .login3-icon::after { border-color: rgba(110, 231, 211, .7); }
.pub-btn-login3 .login3-arrow { color: #6ee7d3; }
.pub-btn-login3:hover, .pub-btn-login3:focus-visible { color: #fff; box-shadow: 0 16px 30px -12px rgba(21, 144, 200, .75); }
.pub-btn-login3:hover .login3-icon, .pub-btn-login3:focus-visible .login3-icon { background: #fff; color: #0b2a4f; }
.pub-btn-login3:hover .login3-arrow, .pub-btn-login3:focus-visible .login3-arrow { color: #fff; }

/* « Se connecter » sobre (21/10/2026) : bleu nuit uni, sans bordure, icône blanche sans cercle, même forme que « Télécharger » */
.pub-btn-login3 { gap: .45rem; padding: .55rem 1.1rem; border: 1px solid #0b2a4f; border-radius: 999px; color: #fff; font-size: .88rem;
    background: #0b2a4f; background-size: auto; box-shadow: 0 6px 16px -10px rgba(11, 42, 79, .8); animation: none !important; }
.pub-btn-login3::before { display: none; }
.pub-btn-login3 .login3-icon { width: auto; height: auto; background: none !important; color: #fff !important; font-size: 1.05rem; border-radius: 0; }
.pub-btn-login3 .login3-icon::after { display: none; }
.pub-btn-login3 .login3-arrow { color: #fff; }
.pub-btn-login3:hover, .pub-btn-login3:focus-visible { color: #fff; background: #12437a; border-color: #12437a; transform: translateY(-1px);
    box-shadow: 0 10px 22px -12px rgba(11, 42, 79, .85); }

/* =====================================================================
   Demande d'abonnement v2 (21/10/2026) : tient dans l'écran, formulaire en deux colonnes, panneau étroit sans vide
   ===================================================================== */
.sub2 { padding: 1.25rem 1rem 1.75rem; display: flex; justify-content: center; }
.sub2-card { width: 100%; max-width: 1240px; display: grid; grid-template-columns: 1fr; border-radius: 24px; overflow: hidden; background: #fff;
    border: 1px solid #e6edf5; box-shadow: 0 26px 60px rgba(11, 42, 79, .12); }
@media (min-width: 992px) { .sub2-card { grid-template-columns: 290px minmax(0, 1fr); } }
.sub2-aside { position: relative; display: none; flex-direction: column; justify-content: space-between; gap: 1.5rem; padding: 2rem 1.75rem; color: #fff; overflow: hidden;
    background: linear-gradient(165deg, #0b2a4f 0%, #0f4f86 55%, #12a8c8 100%); }
@media (min-width: 992px) { .sub2-aside { display: flex; } }
.sub2-aside .pub-hero-glow { inset: -30% -60% auto auto; width: 160%; opacity: .8; }
.sub2-aside > * { position: relative; }
.sub2-aside h2 { font-size: 1.55rem; font-weight: 800; letter-spacing: -.02em; line-height: 1.18; margin: .6rem 0 .6rem; }
.sub2-aside p { opacity: .85; font-size: .88rem; margin: 0; }
.sub2-steps { list-style: none; padding: 0; margin: 0; display: grid; gap: .55rem; }
.sub2-steps li { display: flex; align-items: center; gap: .7rem; padding: .55rem .7rem; border-radius: 13px; background: rgba(255, 255, 255, .08);
    border: 1px solid rgba(255, 255, 255, .14); }
.sub2-steps li > span { width: 1.75rem; height: 1.75rem; border-radius: 50%; display: grid; place-items: center; flex-shrink: 0; font-weight: 800; font-size: .8rem;
    background: linear-gradient(135deg, #16c3a6, #1565c0); }
.sub2-steps strong { display: block; font-size: .88rem; }
.sub2-steps small { opacity: .75; font-size: .74rem; }
.sub2-points { list-style: none; padding: 0; margin: 0; display: grid; gap: .45rem; font-size: .82rem; }
.sub2-points i { color: #6ee7d3; margin-right: .4rem; }

.sub2-main { padding: 1.4rem 1.5rem 1.2rem; }
@media (min-width: 992px) { .sub2-main { padding: 1.6rem 2rem 1.3rem; } }
.sub2-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: .4rem 1rem; margin-bottom: 1rem; }
.sub2-required { font-size: .8rem; color: #6a7a90; }
.sub2-form { display: grid; gap: 0 2rem; grid-template-columns: 1fr; }
@media (min-width: 992px) { .sub2-form { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); } }
.sub2-form .sub2-errors, .sub2-form .hp-field { grid-column: 1 / -1; }
.sub2-form .sub2-errors:empty, .sub2-form .validation-summary-valid { display: none; }
.sub2-col { display: flex; flex-direction: column; min-width: 0; }
.sub2-form fieldset { margin-bottom: .9rem; }
.sub2-form .form-control { min-height: 2.25rem; padding: .38rem .7rem; font-size: .9rem; }
.sub2-kinds { display: grid; grid-template-columns: 1fr 1fr; gap: .55rem; margin-bottom: .6rem; }
.sub2-kinds .acct-kind { padding: .55rem .65rem; gap: .55rem; border-radius: 12px; }
.sub2-kinds .acct-kind-icon { width: 2rem; height: 2rem; font-size: .95rem; border-radius: 10px; }
.sub2-kinds .acct-kind strong { font-size: .86rem; }
.sub2-kinds .acct-kind small { font-size: .74rem; }
.sub2-packs { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.sub2-packs .pub-pick { padding: .55rem .7rem; }
.sub2-submit { margin-top: auto; display: inline-flex; align-items: center; justify-content: center; gap: .5rem; padding: .75rem 1rem; border-radius: 13px; font-weight: 700; }
.sub2-help { font-size: .76rem; margin: .6rem 0 0; }

/* Demande d'abonnement v3 (21/10/2026) : carte à la hauteur du formulaire, colonnes alignées en bas, sans vide */
.sub2 { padding: 1rem 1rem 1.5rem; }
.sub2-card { max-width: 1180px; align-items: stretch; }
@media (min-width: 992px) { .sub2-card { grid-template-columns: 260px minmax(0, 1fr); } }
.sub2-aside { padding: 1.6rem 1.5rem; gap: 1rem; }
.sub2-aside h2 { font-size: 1.32rem; }
.sub2-aside p { font-size: .84rem; }
.sub2-points { gap: .55rem; padding-top: .9rem; border-top: 1px solid rgba(255, 255, 255, .18); }
.sub2-main { display: flex; flex-direction: column; padding: 1.2rem 1.6rem 1rem; }
.sub2-head { margin-bottom: .75rem; }
.sub2-form { flex: 1; align-items: stretch; gap: 0 1.75rem; }
.sub2-col { justify-content: space-between; }
.sub2-form fieldset { margin-bottom: .7rem; }
.sub2-form fieldset:last-of-type { margin-bottom: .6rem; }
.sub2-kinds { margin-bottom: .5rem; }
.sub2-submit { margin-top: auto; }
.sub2-help { grid-column: 1 / -1; display: flex; align-items: center; gap: .4rem; margin: .7rem 0 0; padding-top: .6rem; border-top: 1px solid #eef2f7; }
.sub2-help .bi { color: #16a34a; }
/* Halo décoratif du panneau : en fond, il ne prend pas de place (le texte commence en haut, les garanties restent en bas) */
.sub2-aside > .pub-hero-glow { position: absolute; }

/* =====================================================================
   Demande d'abonnement en étapes qui glissent (21/10/2026)
   ===================================================================== */
.wz-page { position: relative; overflow: hidden; padding: 1.6rem 1rem 2rem; background: radial-gradient(900px 420px at 10% 0%, #e3f4fb 0%, transparent 60%),
    radial-gradient(800px 420px at 95% 100%, #e6f7f2 0%, transparent 60%), #f6f9fc; }
.wz-orb { position: absolute; border-radius: 50%; filter: blur(70px); opacity: .55; pointer-events: none; }
.wz-orb-a { width: 340px; height: 340px; left: -90px; top: 40px; background: #7dd3fc; }
.wz-orb-b { width: 320px; height: 320px; right: -80px; bottom: -60px; background: #5eead4; }
@media (prefers-reduced-motion: no-preference) { .wz-orb { animation: wz-float 14s ease-in-out infinite alternate; } .wz-orb-b { animation-delay: -6s; } }
@keyframes wz-float { from { transform: translate(0, 0) scale(1); } to { transform: translate(40px, 30px) scale(1.08); } }
.wz { position: relative; max-width: 760px; margin: 0 auto; }
.wz-head { text-align: center; margin-bottom: 1.1rem; }
.wz-eyebrow { display: inline-flex; align-items: center; gap: .4rem; padding: .3rem .85rem; border-radius: 999px; background: #fff; border: 1px solid #d8e9f5;
    font-size: .78rem; font-weight: 700; color: #0e7490; letter-spacing: .03em; box-shadow: 0 6px 16px -12px rgba(21, 101, 192, .5); }
.wz-title { margin: .7rem 0 .35rem; font-size: clamp(1.7rem, 3vw, 2.3rem); font-weight: 800; letter-spacing: -.03em; color: #0f1e3d; }
.wz-title span { background: linear-gradient(100deg, #16c3a6, #1590c8); -webkit-background-clip: text; background-clip: text; color: transparent; }
.wz-sub { margin: 0; color: #52627a; font-size: .95rem; }

.wz-card { position: relative; padding: 1.3rem 1.5rem 1.2rem; border-radius: 26px; background: rgba(255, 255, 255, .88); backdrop-filter: blur(14px);
    border: 1px solid rgba(255, 255, 255, .9); box-shadow: 0 30px 70px -30px rgba(11, 42, 79, .35), 0 0 0 1px #e6edf5; }
.wz-card.is-shaking { animation: wz-shake .4s ease; }
@keyframes wz-shake { 20%, 60% { transform: translateX(-6px); } 40%, 80% { transform: translateX(6px); } }

/* Étapes et barre de progression */
.wz-steps { list-style: none; padding: 0; margin: 0; display: grid; grid-template-columns: repeat(4, 1fr); gap: .4rem; }
.wz-steps button { display: flex; flex-direction: column; align-items: center; gap: .3rem; width: 100%; border: 0; background: none; padding: 0; color: #94a3b8;
    font-size: .76rem; font-weight: 600; }
.wz-steps button:disabled { cursor: default; }
.wz-steps em { font-style: normal; }
.wz-steps button > span { width: 2.2rem; height: 2.2rem; border-radius: 50%; display: grid; place-items: center; font-weight: 800; font-size: .85rem;
    background: #fff; border: 2px solid #dbe5ef; color: #94a3b8; transition: background .3s, border-color .3s, color .3s, box-shadow .3s; }
.wz-steps li.is-current button { color: #0f1e3d; }
.wz-steps li.is-current button > span { border-color: transparent; color: #fff; background: linear-gradient(135deg, #16c3a6, #1565c0);
    box-shadow: 0 0 0 5px rgba(22, 195, 166, .18); }
.wz-steps li.is-done button { color: #0e7490; }
.wz-steps li.is-done button > span { border-color: #16c3a6; color: #fff; background: #16c3a6; font-size: 0; }
.wz-steps li.is-done button > span::before { content: "\F26E"; font-family: "bootstrap-icons"; font-size: 1rem; }
.wz-progress { height: 5px; margin: .85rem 0 1rem; border-radius: 999px; background: #e8eef5; overflow: hidden; }
.wz-progress i { display: block; height: 100%; width: 0; border-radius: inherit; background: linear-gradient(90deg, #16c3a6, #1590c8, #1d3fa8);
    transition: width .5s cubic-bezier(.65, 0, .35, 1); }

/* Diapositives : glissement horizontal */
.wz-form.is-ready .wz-viewport { overflow: hidden; margin: 0 -.4rem; padding: 0 .4rem; }
.wz-form.is-ready .wz-track { display: flex; transition: transform .5s cubic-bezier(.65, 0, .35, 1); }
.wz-form.is-ready .wz-slide { flex: 0 0 100%; min-width: 0; padding: .2rem .4rem .3rem; opacity: .25; transition: opacity .45s; }
.wz-form.is-ready .wz-slide.is-current { opacity: 1; }
.wz-form:not(.is-ready) .wz-slide + .wz-slide { margin-top: 1.5rem; padding-top: 1.5rem; border-top: 1px solid #eef2f7; }
.wz-form:not(.is-ready) .wz-nav [data-wz-prev], .wz-form:not(.is-ready) .wz-nav [data-wz-next] { display: none; }
.wz-q { font-size: 1.3rem; font-weight: 800; letter-spacing: -.02em; color: #0f1e3d; margin: 0 0 .2rem; }
.wz-hint { color: #64748b; font-size: .86rem; margin: 0 0 1rem; }
.wz-field .form-label { font-size: .8rem; font-weight: 600; color: #334155; margin-bottom: .3rem; }
.wz-field .form-control { min-height: 2.9rem; border-radius: 13px; border: 1.5px solid #dbe5ef; background: #fbfdff; font-size: .95rem;
    transition: border-color .15s, box-shadow .15s, background .15s; }
.wz-field .form-control:focus { border-color: #1590c8; background: #fff; box-shadow: 0 0 0 4px rgba(21, 144, 200, .14); }
.wz-field .form-control.is-invalid { border-color: #dc2626; box-shadow: 0 0 0 4px rgba(220, 38, 38, .12); background-image: none; }
.wz-input { position: relative; }
.wz-input > .bi { position: absolute; left: .9rem; top: 50%; transform: translateY(-50%); color: #94a3b8; pointer-events: none; }
.wz-input .form-control { padding-left: 2.5rem; }

/* Cartes de choix (type de compte, pack) */
.wz-kinds { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; }
@media (max-width: 575.98px) { .wz-kinds { grid-template-columns: 1fr; } }
.wz-kind, .wz-pack { position: relative; display: flex; flex-direction: column; gap: .3rem; padding: 1.1rem 1.1rem 1rem; margin: 0; border-radius: 18px; cursor: pointer;
    background: #fff; border: 2px solid #e2e8f0; transition: border-color .2s, box-shadow .2s, transform .2s; }
.wz-kind:hover, .wz-pack:hover { border-color: #93c5fd; transform: translateY(-2px); }
.wz-kind strong, .wz-pack strong { font-size: 1rem; color: #0f1e3d; }
.wz-kind small, .wz-pack small { font-size: .8rem; color: #64748b; line-height: 1.4; }
.wz-kind-icon, .wz-pack-icon { width: 2.8rem; height: 2.8rem; border-radius: 14px; display: grid; place-items: center; margin-bottom: .35rem; font-size: 1.25rem;
    color: #1565c0; background: linear-gradient(135deg, #eaf4ff, #e2f7f4); transition: background .2s, color .2s; }
.wz-check { position: absolute; top: .8rem; right: .8rem; width: 1.6rem; height: 1.6rem; border-radius: 50%; display: grid; place-items: center; font-size: .9rem;
    color: #fff; background: linear-gradient(135deg, #16c3a6, #1565c0); transform: scale(0); transition: transform .25s cubic-bezier(.3, 1.6, .5, 1); }
.btn-check:checked + .wz-kind, .wz-pack:has(input:checked) { border-color: transparent; box-shadow: 0 16px 34px -18px rgba(21, 101, 192, .55);
    background: linear-gradient(#fff, #fff) padding-box, linear-gradient(120deg, #16c3a6, #1590c8, #1d3fa8) border-box; }
.btn-check:checked + .wz-kind .wz-check, .wz-pack:has(input:checked) .wz-check { transform: scale(1); }
.btn-check:checked + .wz-kind .wz-kind-icon, .wz-pack:has(input:checked) .wz-pack-icon { color: #fff; background: linear-gradient(135deg, #16c3a6, #1565c0); }
.btn-check:focus-visible + .wz-kind, .wz-pack:has(input:focus-visible) { outline: 3px solid rgba(21, 144, 200, .35); outline-offset: 2px; }
.wz-count { margin-top: .9rem; max-width: 16rem; }
.wz-packs { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: .7rem; border-radius: 18px; }
.wz-packs.is-invalid { outline: 2px solid #dc2626; outline-offset: 4px; }
.wz-pack input { position: absolute; opacity: 0; pointer-events: none; }
.wz-pack { padding: .95rem 1rem; }

/* Navigation */
.wz-nav { display: flex; align-items: center; gap: .8rem; margin-top: 1.1rem; padding-top: 1rem; border-top: 1px solid #eef2f7; }
.wz-back { display: inline-flex; align-items: center; gap: .4rem; padding: .7rem 1rem; border: 0; border-radius: 13px; background: transparent; color: #475569; font-weight: 600; }
.wz-back:hover { background: #f1f5f9; color: #0f1e3d; }
.wz-back[hidden], .wz-next[hidden] { display: none; }
.wz-counter { flex: 1; text-align: center; font-size: .8rem; color: #94a3b8; font-weight: 600; }
.wz-next { display: inline-flex; align-items: center; gap: .55rem; margin-left: auto; padding: .8rem 1.5rem; border: 0; border-radius: 14px; font-weight: 700; color: #fff;
    background: linear-gradient(100deg, #16c3a6 0%, #1590c8 55%, #1d3fa8 100%); box-shadow: 0 14px 28px -14px rgba(21, 101, 192, .8); transition: transform .15s, box-shadow .15s; }
.wz-next:hover { transform: translateY(-1px); box-shadow: 0 18px 32px -14px rgba(21, 101, 192, .9); }
.wz-next .bi-arrow-right { transition: transform .15s; }
.wz-next:hover .bi-arrow-right { transform: translateX(3px); }
.wz-errors:empty, .wz-errors.validation-summary-valid { display: none; }
.wz-trust { list-style: none; padding: 0; margin: 1.1rem 0 0; display: flex; flex-wrap: wrap; justify-content: center; gap: .5rem 1.4rem; font-size: .82rem; color: #475569; }
.wz-trust i { color: #16a34a; margin-right: .35rem; }
@media (prefers-reduced-motion: reduce) { .wz-form.is-ready .wz-track, .wz-progress i { transition: none; } }

.wz-form.is-ready .wz-track { align-items: flex-start; }
.wz-form.is-ready .wz-viewport { transition: height .4s cubic-bezier(.65, 0, .35, 1); }
