/* ==========================================================================
   Plateforme Talent Map : même design que le site de l'événement
   (talentmap-evenement). Couleurs, polices, boutons, cartes, navigation en
   pilule flottante, courbes de niveau et tracé dégradé teal vers orange.
   ========================================================================== */
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces.woff2') format('woff2'); font-weight: 400 700; font-style: normal; font-display: swap; }
@font-face { font-family: 'Fraunces'; src: url('../fonts/fraunces-italic.woff2') format('woff2'); font-weight: 400 600; font-style: italic; font-display: swap; }
@font-face { font-family: 'Inter'; src: url('../fonts/inter.woff2') format('woff2'); font-weight: 400 800; font-display: swap; }

:root {
  --teal: #035966; --teal-2: #0E7C8C; --teal-deep: #012F37;
  --orange: #FF6D08; --orange-text: #B84A00; --orange-display: #E85D00; --orange-soft: #FFE8D6; --on-orange: #16110B;
  --paper: #F6F2EA; --paper-2: #FFFDF9; --ink: #10211F; --ink-soft: #4C5A57; --line: #E2DBCD;
  --heading-teal: #035966; --on-dark: #F3F7F5; --on-dark-soft: #B9D0CC; --on-dark-accent: #FF9A57;
  --surface: var(--paper-2); --sunken: #EFE9DE; --field: var(--paper); --tint: #DCEEF0; --tint-ink: #035966;
  --ok: #17693F; --ok-soft: #DDF3E4; --warn: #8A5A00; --warn-soft: #FFF1CC; --bad: #A5281B; --bad-soft: #FBE2DE;
  --shadow-sm: 0 1px 2px rgba(1, 47, 55, .06), 0 6px 18px rgba(1, 47, 55, .06);
  --shadow-lg: 0 2px 4px rgba(1, 47, 55, .06), 0 24px 60px rgba(1, 47, 55, .14);
  --shadow: var(--shadow-sm);
  --display: 'Fraunces', Georgia, serif; --body: 'Inter', -apple-system, 'Segoe UI', sans-serif;
  --radius: 24px; --radius-lg: 36px; --radius-sm: 16px;
  --route: linear-gradient(90deg, #0E7C8C, #FF6D08);
  color-scheme: light;
}
:root[data-theme="dark"] {
  --orange-text: #FF9A57; --orange-display: #FF8A3D; --orange-soft: #3A2513;
  --paper: #0A1716; --paper-2: #112220; --ink: #EEF4F2; --ink-soft: #A5B8B4; --line: #243633; --heading-teal: #6FC7C2;
  --sunken: #182C29; --field: #0D1C1A; --tint: #123634; --tint-ink: #6FC7C2;
  --ok: #7FD6A4; --ok-soft: #163626; --warn: #F2C35B; --warn-soft: #352A10; --bad: #FF9C8C; --bad-soft: #3A1C18;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 18px rgba(0, 0, 0, .25);
  --shadow-lg: 0 2px 4px rgba(0, 0, 0, .3), 0 24px 60px rgba(0, 0, 0, .45);
  color-scheme: dark;
}

/* ---------- Base ---------- */
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
html, body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--body); font-size: 16px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
body { overflow-x: hidden; }
img { display: block; max-width: 100%; }
a { color: var(--heading-teal); }
:focus-visible { outline: 3px solid var(--orange); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { font-family: var(--display); font-weight: 500; line-height: 1.08; margin: 0; letter-spacing: -.015em; font-variant-numeric: lining-nums; }
h1 em, h2 em { font-style: italic; font-weight: 400; color: var(--orange-display); }
h1 { font-size: clamp(32px, 5vw, 52px); }
h2 { font-size: clamp(22px, 2.4vw, 28px); }
h3 { font-size: 20px; line-height: 1.2; }
p { margin: 0; }
[hidden] { display: none !important; }
.muted { color: var(--ink-soft); }
.small { font-size: 14px; }
.center { text-align: center; }
.mono { font-family: ui-monospace, 'Cascadia Mono', Consolas, monospace; font-size: 13.5px; }
.stack > * + * { margin-top: 14px; }
.stack-sm > * + * { margin-top: 10px; }
.stack-md > * + * { margin-top: 18px; }
.stack-lg > * + * { margin-top: 24px; }
.row { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; }
.spread { justify-content: space-between; }
.prewrap { white-space: pre-wrap; overflow-wrap: anywhere; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.ico { flex: none; }

/* Surtitre du site : petit trait dégradé puis texte en capitales */
.eyebrow { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 12px; letter-spacing: .16em; text-transform: uppercase; color: var(--heading-teal); }
.eyebrow::before { content: ""; width: 28px; height: 2px; border-radius: 2px; background: var(--route); }
.on-dark .eyebrow { color: #8FD8CF; }

/* Courbes de niveau, comme sur les sections du site */
.contours, .contours-light { position: relative; overflow: hidden; }
.contours::before { content: ""; position: absolute; inset: 0; background: url("../img/contours-white.svg") center / 1400px auto; opacity: .09; pointer-events: none; }
.contours-light::before { content: ""; position: absolute; inset: 0; background: url("../img/contours-teal.svg") center top / 1400px auto; opacity: .14; pointer-events: none; }
[data-theme="dark"] .contours-light::before { background-image: url("../img/contours-white.svg"); opacity: .05; }
.contours > *, .contours-light > * { position: relative; }

/* ---------- Navigation : pilule flottante du site ---------- */
header.site { position: sticky; top: 12px; z-index: 50; margin: 12px 0 0; padding: 0 20px; }
.nav-row { position: relative; display: flex; align-items: center; justify-content: space-between; gap: 14px; max-width: 1240px; margin: 0 auto; padding: 8px 9px 8px 14px; background: color-mix(in srgb, var(--paper-2) 86%, transparent); -webkit-backdrop-filter: blur(14px); backdrop-filter: blur(14px); border: 1px solid var(--line); border-radius: 999px; box-shadow: var(--shadow-sm); }
.brand { display: flex; align-items: center; gap: 10px; white-space: nowrap; text-decoration: none; color: inherit; }
.brand .badge { width: 42px; height: 42px; flex: none; }
.wordmark { display: block; font-weight: 800; font-size: 16px; letter-spacing: .03em; text-transform: uppercase; color: var(--heading-teal); line-height: 1.15; }
.wordmark b { font-weight: 800; color: var(--orange-display); }
.brand-tag { display: block; font-weight: 500; font-size: 11.5px; color: var(--ink-soft); margin-top: 1px; }
nav.links { display: flex; gap: 2px; align-items: center; }
nav.links a { position: relative; display: inline-flex; align-items: center; gap: 7px; white-space: nowrap; font-size: 14.5px; font-weight: 600; text-decoration: none; color: var(--ink-soft); padding: 9px 14px; border-radius: 999px; transition: color .15s, background .15s; }
nav.links a:hover { color: var(--ink); background: color-mix(in srgb, var(--heading-teal) 10%, transparent); }
nav.links a[aria-current="page"] { color: var(--paper-2); background: var(--heading-teal); }
.nav-actions { display: flex; align-items: center; gap: 8px; }
.theme-btn, .menu-btn { width: 42px; height: 42px; border-radius: 50%; border: 1px solid var(--line); background: var(--paper-2); display: flex; align-items: center; justify-content: center; cursor: pointer; color: var(--ink); flex: none; padding: 0; transition: border-color .15s, color .15s; }
.theme-btn:hover, .menu-btn:hover { border-color: var(--heading-teal); color: var(--heading-teal); }
.theme-btn svg, .menu-btn svg { width: 18px; height: 18px; }
.i-moon, [data-theme="dark"] .i-sun, .menu-btn .i-close, .menu-btn[aria-expanded="true"] .i-burger { display: none; }
[data-theme="dark"] .i-moon, .menu-btn[aria-expanded="true"] .i-close { display: block; }
.menu-btn { display: none; }
.nav-pill { display: inline-flex; align-items: center; gap: 7px; padding: 8px 14px; border-radius: 999px; background: var(--orange-soft); color: var(--orange-text); font-weight: 700; font-size: 13.5px; white-space: nowrap; }
@media (max-width: 600px) {
  header.site { padding: 0 12px; }
  .brand .badge { width: 38px; height: 38px; }
  .wordmark { font-size: 14.5px; }
}

/* ---------- Boutons du site ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 9px; min-height: 48px; border-radius: 999px; padding: 13px 24px; font: 700 15px var(--body); cursor: pointer; border: none; text-decoration: none; white-space: nowrap; transition: transform .2s ease, box-shadow .2s ease, background .2s ease, color .2s ease; }
.btn svg { width: 16px; height: 16px; transition: transform .2s ease; }
.btn:hover:not([disabled]) .i-go { transform: translateX(3px); }
.btn-primary { background: var(--orange); color: var(--on-orange); box-shadow: 0 10px 26px rgba(255, 109, 8, .32); }
.btn-primary:hover:not([disabled]) { transform: translateY(-2px); box-shadow: 0 14px 32px rgba(255, 109, 8, .42); }
.btn-ghost { background: transparent; color: var(--ink); box-shadow: inset 0 0 0 1.5px var(--line); }
.btn-ghost:hover:not([disabled]) { box-shadow: inset 0 0 0 1.5px var(--heading-teal); color: var(--heading-teal); }
.btn-dark { background: var(--teal-deep); color: #fff; }
[data-theme="dark"] .btn-dark { background: var(--teal); }
.btn-dark:hover:not([disabled]) { transform: translateY(-2px); }
.btn-light { background: #fff; color: var(--teal-deep); }
.btn-light:hover:not([disabled]) { transform: translateY(-2px); }
.btn-outline-light { background: transparent; color: var(--on-dark); box-shadow: inset 0 0 0 1.5px rgba(255, 255, 255, .35); }
.btn-outline-light:hover:not([disabled]) { box-shadow: inset 0 0 0 1.5px #fff; }
.btn-danger { background: var(--bad); color: #fff; }
[data-theme="dark"] .btn-danger { color: #1A0A08; }
.btn-link { background: transparent; color: var(--heading-teal); padding-left: 10px; padding-right: 10px; }
.btn-link:hover:not([disabled]) { background: color-mix(in srgb, var(--heading-teal) 10%, transparent); }
.btn-link.danger { color: var(--bad); }
.btn-sm { min-height: 40px; padding: 9px 18px; font-size: 14px; }
.btn-icon { width: 40px; min-height: 40px; padding: 0; }
.btn-block { width: 100%; }
.btn[disabled] { opacity: .45; cursor: not-allowed; box-shadow: none; }
label.btn { margin-bottom: 0; } /* bouton d'import de fichier : sans la marge des libellés de formulaire */

/* ---------- Cartes et blocs ---------- */
.card { background: var(--paper-2); border: 1px solid var(--line); border-radius: var(--radius); padding: 24px; box-shadow: var(--shadow-sm); }
.dark-card { background: var(--teal-deep); color: var(--on-dark); border: 0; border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.dark-card h1, .dark-card h2 { color: var(--on-dark); }
.dark-card h1 em, .dark-card h2 em { color: var(--on-dark-accent); }
.dark-card .muted, .dark-card p { color: var(--on-dark-soft); }
.note-box { background: var(--orange-soft); border-radius: 18px; padding: 18px 22px; font-size: 15px; line-height: 1.55; }
.note-box b { color: var(--orange-text); }

.notice { border-radius: 14px; padding: 12px 15px; font-size: 14.5px; background: var(--orange-soft); }
.notice-ok { background: var(--ok-soft); color: var(--ok); }
.notice-bad { background: var(--bad-soft); color: var(--bad); }
.notice-warn { background: var(--warn-soft); color: var(--warn); }

.pill { display: inline-flex; align-items: center; gap: 5px; padding: 4px 12px; border-radius: 999px; font-size: 12.5px; font-weight: 700; background: var(--sunken); color: var(--ink); white-space: nowrap; }
.pill-ok { background: var(--ok-soft); color: var(--ok); }
.pill-warn { background: var(--warn-soft); color: var(--warn); }
.pill-bad { background: var(--bad-soft); color: var(--bad); }
.pill-teal { background: var(--tint); color: var(--tint-ink); }

.avatar { display: inline-grid; place-items: center; flex: none; width: 40px; height: 40px; border-radius: 50%; font-size: 13.5px; font-weight: 700; letter-spacing: .02em; }
.avatar-lg { width: 64px; height: 64px; font-size: 21px; }
.avatar-0 { background: var(--tint); color: var(--tint-ink); }
.avatar-1 { background: var(--orange-soft); color: var(--orange-text); }
.avatar-2 { background: #E6E1F5; color: #4B3C8C; }
.avatar-3 { background: var(--ok-soft); color: var(--ok); }
.avatar-4 { background: #F7E0E6; color: #8C2E4B; }
[data-theme="dark"] .avatar-2 { background: #262040; color: #C3B6FF; }
[data-theme="dark"] .avatar-4 { background: #3A1C27; color: #FFB3C7; }
.person { display: flex; align-items: center; gap: 12px; min-width: 0; }
.person > div, .person > span:last-child { display: grid; min-width: 0; }
.person small { color: var(--ink-soft); font-size: 13px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.person strong { font-weight: 600; }
.person-lg h1 { font-size: clamp(30px, 4.6vw, 46px); }
.is-off { opacity: .55; }

/* Barre de progression : le tracé dégradé du logo */
.bar { display: block; height: 7px; border-radius: 999px; background: var(--sunken); overflow: hidden; }
.bar-fill { display: block; height: 100%; border-radius: inherit; background: var(--route); transition: width .6s ease; }
.bar-orange .bar-fill { background: var(--orange); }
.bar-light { background: rgba(255, 255, 255, .14); }

.banner { display: flex; align-items: center; gap: 12px; padding: 14px 18px; border-radius: 18px; font-size: 14.5px; }
.banner p { flex: 1; }
.banner-warn { background: var(--warn-soft); color: var(--warn); }
.banner-bad { background: var(--bad-soft); color: var(--bad); }
.banner-ok { background: var(--ok-soft); color: var(--ok); }
.banner-info { background: var(--tint); color: var(--tint-ink); }
.banner .btn { min-height: 34px; padding: 6px 14px; }

.empty { display: grid; justify-items: center; gap: 8px; text-align: center; padding: 56px 20px; border: 1.5px dashed var(--line); border-radius: var(--radius); }
.empty-ico { display: grid; place-items: center; width: 60px; height: 60px; border-radius: 50%; background: var(--orange-soft); color: var(--orange-text); margin-bottom: 6px; }
.empty h3 { font-size: 22px; }
.empty p { max-width: 460px; }
.empty .btn { margin-top: 10px; }

/* Niveaux de l'échelle */
.lvl-1 { --lvl: #F9DCD3; --lvl-ink: #8A3B22; }
.lvl-2 { --lvl: #FFF0CC; --lvl-ink: #7A5200; }
.lvl-3 { --lvl: #D9EFF1; --lvl-ink: #035966; }
.lvl-4 { --lvl: #D7F0DF; --lvl-ink: #17693F; }
[data-theme="dark"] .lvl-1 { --lvl: #3A1F16; --lvl-ink: #FFB49A; }
[data-theme="dark"] .lvl-2 { --lvl: #352A10; --lvl-ink: #F2C35B; }
[data-theme="dark"] .lvl-3 { --lvl: #123634; --lvl-ink: #6FC7C2; }
[data-theme="dark"] .lvl-4 { --lvl: #163626; --lvl-ink: #7FD6A4; }

/* ---------- Formulaires du site ---------- */
label { display: block; font-size: 13.5px; font-weight: 600; margin-bottom: 7px; color: var(--ink); }
input[type=text], input[type=email], input[type=tel], input[type=password], input[type=time], input[type=search], select, textarea { width: 100%; padding: 13px 15px; border: 1.5px solid var(--line); border-radius: 14px; background: var(--field); color: var(--ink); font: 16px var(--body); transition: border-color .15s, box-shadow .15s; -webkit-appearance: none; appearance: none; }
select { background-image: linear-gradient(45deg, transparent 50%, var(--ink-soft) 50%), linear-gradient(135deg, var(--ink-soft) 50%, transparent 50%); background-position: calc(100% - 20px) 50%, calc(100% - 15px) 50%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 38px; }
input::placeholder, textarea::placeholder { color: var(--ink-soft); opacity: .75; }
textarea { min-height: 96px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--teal-2); box-shadow: 0 0 0 4px color-mix(in srgb, var(--teal-2) 18%, transparent); }
input:disabled, textarea:disabled, select:disabled { opacity: .7; }
.check { display: flex; gap: 10px; align-items: flex-start; font-weight: 400; font-size: 15px; }
.check input { width: 20px; height: 20px; margin-top: 2px; flex: none; accent-color: var(--teal); }
.field { display: grid; gap: 6px; align-content: start; }
.field label { margin: 0; }
.grid-2 { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 16px; }
.grid-3 { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 16px; }
.span-all { grid-column: 1 / -1; }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; flex-wrap: wrap; }

/* ---------- Pages de connexion ---------- */
.auth-body { min-height: 100vh; display: flex; flex-direction: column; }
.auth { flex: 1; display: flex; align-items: center; justify-content: center; padding: 40px 16px 56px; }
.auth .card { width: 100%; max-width: 460px; padding: clamp(26px, 4vw, 38px); border-radius: var(--radius-lg); box-shadow: var(--shadow-lg); }
.auth .card > img { width: 64px; height: 64px; margin-bottom: 4px; }
.auth h1 { font-size: clamp(32px, 6vw, 42px); }
.auth details { border-top: 1px solid var(--line); padding-top: 14px; }
.auth summary { cursor: pointer; font-weight: 600; color: var(--ink-soft); }
.auth summary:hover { color: var(--heading-teal); }
.foot-note { text-align: center; padding: 0 16px 28px; font-size: 13px; color: var(--ink-soft); }
.foot-note a { color: var(--heading-teal); font-weight: 600; text-underline-offset: 3px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: .01ms !important; animation-delay: 0s !important; transition-duration: .01ms !important; }
}
@media print {
  header.site, .no-print, .bottom-bar { display: none !important; }
  html, body { background: #fff; }
  .card { box-shadow: none; break-inside: avoid; }
}
