/* Layout : un tableau des postes comme cœur du site ; couleurs du logo NeufCom (bleu marine « Neuf », orange « Com »), grille à 12 colonnes */
:root {
  --paper: #F4F5F7;
  --surface: #FFFFFF;
  --ink: #1C2633;
  --muted: #56606E;
  --line: #DADEE4;
  --brand: #283546;          /* bleu marine du logo */
  --brand-ink: #FFFFFF;
  --brand-muted: #B3BDCA;
  --logo-orange: #E13B13;    /* orange du logo */
  --saffron: #C9340F;        /* orange des boutons, lisible avec texte blanc */
  --saffron-ink: #FFFFFF;
  --on-brand-accent: #FF7A52; /* orange lisible sur fond marine */
  --link: #C9340F;
  --header-bg: #FFFFFF;
  --header-ink: #283546;
  --font-display: "Familjen Grotesk", "Helvetica Neue", Arial, sans-serif;
  --font-body: "Libre Franklin", "Helvetica Neue", Arial, sans-serif;
}
@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --paper: #10161E; --surface: #17202B; --ink: #EEF1F5; --muted: #A9B3C0; --line: #2A3542;
    --brand: #1A2533; --brand-ink: #FFFFFF; --brand-muted: #A6B2C1; --logo-orange: #F0522A;
    --saffron: #D93C14; --saffron-ink: #FFFFFF; --on-brand-accent: #FF8A64; --link: #FF8A64;
    --header-bg: #17202B; --header-ink: #EEF1F5; color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --paper: #10161E; --surface: #17202B; --ink: #EEF1F5; --muted: #A9B3C0; --line: #2A3542;
  --brand: #1A2533; --brand-ink: #FFFFFF; --brand-muted: #A6B2C1; --logo-orange: #F0522A;
  --saffron: #D93C14; --saffron-ink: #FFFFFF; --on-brand-accent: #FF8A64; --link: #FF8A64;
  --header-bg: #17202B; --header-ink: #EEF1F5; color-scheme: dark;
}
.logo-img { display: block; height: 30px; width: auto; }
.logo-img--light { display: none; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .site-header .logo-img--dark { display: none; } :root:not([data-theme="light"]) .site-header .logo-img--light { display: block; } }
:root[data-theme="dark"] .site-header .logo-img--dark { display: none; }
:root[data-theme="dark"] .site-header .logo-img--light { display: block; }
.site-footer .logo-img--dark { display: none; }
.site-footer .logo-img--light { display: block; }

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } * { transition: none !important; } }
body { margin: 0; background: var(--paper); color: var(--ink); font-family: var(--font-body); font-size: 17px; line-height: 1.6; font-variant-numeric: tabular-nums; }
body::before { content: ""; position: fixed; inset: 0 0 auto; height: env(safe-area-inset-top, 0px); z-index: 30; background: var(--header-bg); }
a { color: var(--link); }
:focus-visible { outline: 3px solid var(--saffron); outline-offset: 2px; }
h1, h2, h3 { font-family: var(--font-display); margin: 0; line-height: 1.02; text-wrap: balance; letter-spacing: -0.015em; }
h1 { font-size: clamp(2.8rem, 7.4vw, 6.2rem); font-weight: 700; letter-spacing: -0.035em; }
h2 { font-size: clamp(2rem, 4.2vw, 3.4rem); font-weight: 700; letter-spacing: -0.025em; }
h3 { font-size: 1.35rem; font-weight: 700; }
p { margin: 0; }
.lead { font-size: 1.2rem; max-width: 56ch; color: var(--muted); }
.todo { background: #FFE08A; color: #2A1D00; padding: 0 0.3em; }

.wrap { max-width: 1240px; margin: 0 auto; padding-left: max(16px, env(safe-area-inset-left, 0px)); padding-right: max(16px, env(safe-area-inset-right, 0px)); }
.band { padding-block: clamp(56px, 8vw, 112px); }
.band--white { background: var(--surface); }
.band--brand { background: var(--brand); color: var(--brand-ink); }
.band--brand .lead, .band--brand .muted { color: var(--brand-muted); }
.stack { display: flex; flex-direction: column; gap: 16px; }
.label { font-weight: 600; font-size: 0.95rem; color: var(--muted); }
.band--brand .label, .hero .label, .page-head .label { color: var(--on-brand-accent) !important; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 10px; min-height: 52px; padding: 0 26px; font: 600 1rem/1 var(--font-body); text-decoration: none; border: 2px solid transparent; border-radius: 0; cursor: pointer; transition: background .15s, color .15s; }
.btn--saffron { background: var(--saffron); color: var(--saffron-ink); }
.btn--saffron:hover { background: color-mix(in srgb, var(--saffron) 85%, #000); }
.btn--line { background: transparent; color: inherit; border-color: currentColor; }
.btn--line:hover { background: color-mix(in srgb, currentColor 10%, transparent); }
.btn--ink { background: var(--ink); color: var(--paper); }
.arrow { display: inline-block; transition: transform .15s; }
a:hover .arrow, button:hover .arrow { transform: translateX(4px); }

/* En-tête */
.site-header { position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20; background: var(--header-bg); color: var(--header-ink); border-bottom: 3px solid var(--logo-orange); }
.site-header .wrap { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 28px; padding-block: 14px; }
.logo { color: var(--brand-ink); text-decoration: none; font-family: var(--font-display); font-weight: 700; font-size: 1.5rem; letter-spacing: -0.03em; display: inline-flex; align-items: baseline; gap: 2px; }
.logo i { font-style: normal; color: var(--saffron); }
.site-nav { display: flex; flex-wrap: wrap; gap: 4px 28px; font-weight: 500; }
.site-nav a { color: var(--header-ink); text-decoration: none; padding: 6px 0; border-bottom: 2px solid transparent; font-weight: 600; }
.site-nav a:hover, .site-nav a[aria-current="page"] { border-bottom-color: var(--logo-orange); }
.site-header .btn { min-height: 44px; padding: 0 18px; font-size: 0.95rem; }
@media (max-width: 860px) { .site-nav { order: 3; width: 100%; overflow-x: auto; flex-wrap: nowrap; } }

/* Hero talents */
.hero { background: var(--brand); color: var(--brand-ink); padding-block: clamp(48px, 7vw, 96px) 0; overflow: hidden; }
.hero-grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; align-items: end; }
.hero-title { grid-column: 1 / span 8; display: flex; flex-direction: column; gap: 26px; padding-bottom: clamp(40px, 6vw, 72px); }
.hero-title h1 em { font-style: normal; color: var(--on-brand-accent); }
.hero-title .lead { color: var(--brand-muted); }
.hero-ctas { display: flex; flex-wrap: wrap; gap: 12px; }
.hero-board { grid-column: 9 / span 4; background: var(--surface); color: var(--ink); padding: 26px 26px 0; display: flex; flex-direction: column; gap: 18px; align-self: end; }
.hero-board .big { font-family: var(--font-display); font-weight: 700; font-size: 5.4rem; line-height: 0.9; letter-spacing: -0.04em; }
.hero-board .big small { font-size: 1.1rem; letter-spacing: 0; font-family: var(--font-body); font-weight: 500; color: var(--muted); display: block; margin-top: 8px; }
.city-split { display: grid; grid-template-columns: 1fr 1fr; border-top: 1px solid var(--line); }
.city-split div { padding: 16px 0; display: flex; flex-direction: column; gap: 2px; }
.city-split div + div { border-left: 1px solid var(--line); padding-left: 18px; }
.city-split b { font-family: var(--font-display); font-size: 2rem; letter-spacing: -0.02em; }
.city-split span { color: var(--muted); font-size: 0.93rem; }
@media (max-width: 920px) { .hero-title, .hero-board { grid-column: 1 / -1; } .hero-board { margin-inline: calc(-1 * max(16px, env(safe-area-inset-left, 0px))); } }

/* Bandeau métiers */
.trades { background: var(--saffron); color: var(--saffron-ink); }
.trades .wrap { display: flex; flex-wrap: wrap; gap: 6px 28px; padding-block: 18px; font-family: var(--font-display); font-weight: 700; font-size: clamp(1.1rem, 2vw, 1.5rem); letter-spacing: -0.01em; }
.trades span:not(:last-child)::after { content: "/"; margin-left: 28px; opacity: 0.45; font-weight: 400; }

/* Tableau des postes */
.board-head { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: end; gap: 20px; margin-bottom: 28px; }
.filters { display: flex; flex-direction: column; gap: 12px; margin-bottom: 8px; }
.filter-row { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.filter-row > span { font-weight: 600; font-size: 0.9rem; color: var(--muted); min-width: 72px; }
.chip { font: 500 0.95rem var(--font-body); min-height: 40px; padding: 0 16px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; border-radius: 999px; }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); border-color: var(--ink); }
.count { font-family: var(--font-display); font-weight: 700; font-size: 1.15rem; }
/* Offres en cartes (carreaux) */
.jobs { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 16px; }
.job { display: flex; }
.job a { position: relative; display: flex; flex-direction: column; gap: 14px; width: 100%; min-height: 190px; padding: 22px 22px 20px; background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--ink); text-decoration: none; color: var(--ink); transition: border-color .15s, transform .15s, box-shadow .15s; }
.job a:hover, .job a:focus-visible { border-top-color: var(--saffron); transform: translateY(-3px); box-shadow: 0 10px 24px rgba(28, 38, 51, .10); }
.job h3 { order: 2; font-size: clamp(1.15rem, 1.8vw, 1.35rem); font-weight: 700; letter-spacing: -0.01em; line-height: 1.25; }
.job .meta { order: 1; display: flex; flex-wrap: wrap; gap: 6px 8px; font-size: 0.85rem; color: var(--muted); }
.job .meta > * { padding: 4px 10px; border: 1px solid var(--line); border-radius: 999px; white-space: nowrap; }
.job .meta b { font-weight: 600; color: var(--saffron-ink); background: var(--saffron); border-color: var(--saffron); }
.job .go { order: 3; margin-top: auto; align-self: flex-end; font-size: 1.4rem; transition: transform .15s; }
.job a:hover .go { transform: translateX(4px); }
@media (max-width: 680px) { .jobs { grid-template-columns: 1fr; gap: 12px; } .job a { min-height: 0; } }
.empty { padding: 28px 4px; color: var(--muted); border-bottom: 1px solid var(--line); }

/* Parcours */
.path { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); counter-reset: p; }
@media (max-width: 920px) { .path { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .path { grid-template-columns: minmax(0, 1fr); } }
.path li { counter-increment: p; padding: 0 24px 0 0; display: flex; flex-direction: column; gap: 12px; }
.path li::before { content: counter(p); font-family: var(--font-display); font-weight: 700; font-size: 4rem; line-height: 1; color: var(--on-brand-accent); }
.path li + li { border-left: 1px solid color-mix(in srgb, var(--brand-ink) 22%, transparent); padding-left: 24px; }
@media (max-width: 920px) { .path li { padding: 20px 0 !important; border-left: 0 !important; border-top: 1px solid color-mix(in srgb, var(--brand-ink) 22%, transparent); } }
.path p { color: var(--brand-muted); }

/* Pourquoi nous rejoindre */
.reasons { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; }
.reasons > header { grid-column: 1 / span 4; display: flex; flex-direction: column; gap: 14px; }
.reason-list { grid-column: 6 / span 7; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0; border-top: 2px solid var(--ink); }
.reason { padding: 22px 20px 22px 0; border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 8px; }
.reason:nth-child(odd) { border-right: 1px solid var(--line); }
.reason:nth-child(even) { padding-left: 20px; }
.reason p { color: var(--muted); }
@media (max-width: 920px) { .reasons > header, .reason-list { grid-column: 1 / -1; } }
@media (max-width: 560px) { .reason-list { grid-template-columns: minmax(0, 1fr); } .reason:nth-child(odd) { border-right: 0; } .reason:nth-child(even) { padding-left: 0; } }

/* Formulaires */
.apply { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; }
.apply > header { grid-column: 1 / span 4; display: flex; flex-direction: column; gap: 16px; }
.apply form { grid-column: 6 / span 7; display: flex; flex-direction: column; gap: 22px; scroll-margin-top: 100px; }
@media (max-width: 920px) { .apply > header, .apply form { grid-column: 1 / -1; } }
.fields { display: grid; grid-template-columns: repeat(auto-fit, minmax(230px, 1fr)); gap: 18px 20px; }
.field { display: flex; flex-direction: column; gap: 6px; font-weight: 600; font-size: 0.95rem; }
.field input, .field select, .field textarea { font: 400 1.02rem var(--font-body); color: var(--ink); background: transparent; border: 0; border-bottom: 2px solid var(--line); border-radius: 0; min-height: 48px; padding: 0 2px; width: 100%; }
.field select { background: var(--paper); }
.band--white .field select { background: var(--surface); }
.field input[type="file"] { padding: 12px 2px; border-bottom-style: dashed; }
.field textarea { min-height: 110px; padding: 10px 2px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--link); }
.field small { font-weight: 400; color: var(--muted); }
.consent { display: flex; gap: 12px; align-items: flex-start; font-size: 0.92rem; color: var(--muted); }
.consent input { accent-color: var(--brand); width: 20px; height: 20px; margin: 3px 0 0; flex: none; }
.picks { display: flex; flex-wrap: wrap; gap: 8px; }
.pick { display: inline-flex; align-items: center; gap: 10px; min-height: 46px; padding: 0 16px; border: 1.5px solid var(--line); cursor: pointer; font-weight: 500; }
.pick input { accent-color: var(--brand); width: 18px; height: 18px; margin: 0; }
.pick:has(input:checked) { border-color: var(--logo-orange); background: color-mix(in srgb, var(--logo-orange) 12%, transparent); }
fieldset { border: 0; margin: 0; padding: 0; min-width: 0; }
legend { font-weight: 600; font-size: 0.95rem; margin-bottom: 10px; padding: 0; }
.form-error { color: #B42318; font-weight: 600; }
:root[data-theme="dark"] .form-error { color: #FF8A7A; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .form-error { color: #FF8A7A; } }
.done { border-left: 4px solid var(--logo-orange); background: var(--surface); padding: 24px 28px; display: flex; flex-direction: column; gap: 8px; }

/* Entreprises */
.offer-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); border-top: 2px solid var(--ink); }
@media (max-width: 920px) { .offer-grid { grid-template-columns: minmax(0, 1fr); } }
.offer { padding: 28px 24px 32px 0; display: flex; flex-direction: column; gap: 14px; border-bottom: 1px solid var(--line); }
.offer + .offer { border-left: 1px solid var(--line); padding-left: 24px; }
@media (max-width: 920px) { .offer + .offer { border-left: 0; padding-left: 0; } }
.offer ul { margin: 0; padding-left: 18px; color: var(--muted); display: flex; flex-direction: column; gap: 4px; }
.offer .num { font-family: var(--font-display); font-weight: 700; color: var(--link); }
.figures { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 0; border-top: 1px solid color-mix(in srgb, var(--brand-ink) 22%, transparent); }
.figures div { padding: 24px 20px 0 0; display: flex; flex-direction: column; gap: 4px; }
.figures b { font-family: var(--font-display); font-size: clamp(2.4rem, 4.6vw, 3.6rem); letter-spacing: -0.03em; line-height: 1; }
.figures span { color: var(--brand-muted); }
@media (max-width: 720px) { .figures { grid-template-columns: repeat(2, minmax(0, 1fr)); row-gap: 20px; } }
.offices { display: grid; grid-template-columns: 1fr 1fr; gap: 0; border-top: 2px solid var(--ink); }
.offices article { padding: 24px 24px 24px 0; display: flex; flex-direction: column; gap: 8px; }
.offices article + article { border-left: 1px solid var(--line); padding-left: 24px; }
.offices p { color: var(--muted); }
@media (max-width: 640px) { .offices { grid-template-columns: minmax(0, 1fr); } .offices article + article { border-left: 0; padding-left: 0; border-top: 1px solid var(--line); } }

/* Pied de page */
.site-footer { background: var(--ink); color: var(--paper); padding-block: 56px 28px; font-size: 0.95rem; }
:root[data-theme="dark"] .site-footer { background: #070A0B; color: #EDF1EF; }
@media (prefers-color-scheme: dark) { :root:not([data-theme="light"]) .site-footer { background: #070A0B; color: #EDF1EF; } }
.footer-top { display: grid; grid-template-columns: minmax(0, 1.4fr) repeat(3, minmax(0, 1fr)); gap: 28px; }
@media (max-width: 820px) { .footer-top { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
.footer-top nav { display: flex; flex-direction: column; gap: 8px; }
.footer-top strong { font-family: var(--font-display); font-size: 1.05rem; }
.site-footer a { color: inherit; opacity: 0.78; text-decoration: none; }
.site-footer a:hover { opacity: 1; text-decoration: underline; }
.site-footer .logo { opacity: 1; color: inherit; }
.footer-legal { margin-top: 36px; padding-top: 18px; border-top: 1px solid rgba(255, 255, 255, 0.16); display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px 24px; opacity: 0.8; font-size: 0.88rem; }
.footer-legal nav { display: flex; gap: 16px; flex-wrap: wrap; }
.site-footer { background: var(--brand) !important; color: var(--brand-ink) !important; border-top: 3px solid var(--logo-orange); }
.site-footer .logo-img { height: 26px; }

/* Pages légales */
.page-head { background: var(--brand); color: var(--brand-ink); padding-block: 56px 44px; }
.page-head .wrap { display: flex; flex-direction: column; gap: 12px; }
.page-head h1 { font-size: clamp(2.3rem, 5vw, 4rem); }
.page-head .lead { color: var(--brand-muted); }
.legal { max-width: 780px; padding-block: 48px 88px; display: flex; flex-direction: column; gap: 34px; }
.legal section { display: flex; flex-direction: column; gap: 10px; }
.legal h2 { font-size: 1.5rem; }
.legal ul { margin: 0; padding-left: 22px; display: flex; flex-direction: column; gap: 6px; }
.table-scroll { overflow-x: auto; border-top: 2px solid var(--ink); }
.table-scroll table { width: 100%; min-width: 540px; border-collapse: collapse; font-size: 0.95rem; }
.table-scroll th, .table-scroll td { text-align: left; padding: 12px 10px 12px 0; border-bottom: 1px solid var(--line); vertical-align: top; }

/* L attribut hidden doit toujours masquer, meme sur les elements en flex/grid */
[hidden]{display:none !important}

/* Fiches poste (offre-*.html) */
.back-link { color: var(--brand-muted); text-decoration: none; font-weight: 500; font-size: 0.95rem; align-self: flex-start; }
.back-link:hover { color: var(--brand-ink); text-decoration: underline; }
.page-head .hero-ctas { margin-top: 8px; }
.job-layout { display: grid; grid-template-columns: minmax(0, 1fr) 320px; gap: 48px; align-items: start; }
.job-body { max-width: none; }
.job-aside { position: sticky; top: 96px; margin-block: 48px; padding: 24px; background: var(--surface); border: 1px solid var(--line); border-top: 4px solid var(--saffron); display: flex; flex-direction: column; gap: 18px; }
.job-facts { margin: 0; display: flex; flex-direction: column; gap: 14px; }
.job-facts div { display: flex; flex-direction: column; gap: 2px; padding-bottom: 12px; border-bottom: 1px solid var(--line); }
.job-facts dt { font-size: 0.85rem; color: var(--muted); font-weight: 600; }
.job-facts dd { margin: 0; font-weight: 600; }
.job-aside .btn { width: 100%; }
.job-aside-link { font-size: 0.9rem; color: var(--muted); text-align: center; }
@media (max-width: 900px) { .job-layout { grid-template-columns: 1fr; gap: 0; } .job-aside { position: static; margin-block: 0 48px; order: -1; margin-top: 32px; } }
