/* Espace membre Poweryx : même univers que le site (nuit sur La Défense, lumière des fenêtres). */
:root {
  color-scheme: light;
  --night: #0A1128; --night-2: #141F45; --on-night: #EEF1FA; --on-night-muted: #AAB4D2;
  --paper: #F4F5F9; --surface: #FFFFFF; --ink: #0A1128; --muted: #59627D; --line: #D9DDEA;
  --amber: #FFC24B; --amber-soft: #FFF0CC; --red: #B3261E; --red-soft: #FBE9E7;
  --display: "Bricolage Grotesque", "Arial Narrow", "Helvetica Neue", Arial, sans-serif;
  --accent-face: "Instrument Serif", Georgia, "Times New Roman", serif;
  --body: "IBM Plex Sans", "Segoe UI", Helvetica, Arial, sans-serif;
  --mono: "IBM Plex Mono", "SFMono-Regular", Consolas, monospace;
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; font-family: var(--body); font-size: 17px; line-height: 1.55; color: var(--ink); background: var(--paper); min-height: 100vh; display: flex; flex-direction: column; -webkit-font-smoothing: antialiased; }
main { flex: 1; padding-top: 40px; padding-bottom: 64px; }
a { color: inherit; }
:focus-visible { outline: 3px solid var(--amber); outline-offset: 2px; border-radius: 3px; }
h1, h2 { font-family: var(--display); letter-spacing: -0.025em; margin: 0; text-wrap: balance; }
h1 { font-size: clamp(2rem, 4.6vw, 3.4rem); line-height: 1; font-weight: 800; }
h1.petit { font-size: clamp(1.6rem, 3vw, 2.1rem); line-height: 1.1; }
h2 { font-size: 1.35rem; line-height: 1.2; font-weight: 700; }
h1 em { font-family: var(--accent-face); font-style: italic; font-weight: 400; letter-spacing: -0.01em; }
p { margin: 0; }
.cadre { width: 100%; max-width: 1140px; margin: 0 auto; padding-left: 24px; padding-right: 24px; }
.etiquette { font-family: var(--mono); font-size: 0.78rem; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted); }
.aide { font-weight: 400; color: var(--muted); font-size: 0.86em; }
.note { font-size: 0.86rem; color: var(--muted); margin-top: 18px; max-width: 60em; }

/* Barre */
.barre { background: var(--night); color: var(--on-night); }
.barre .cadre { display: flex; justify-content: space-between; align-items: center; gap: 10px 20px; flex-wrap: wrap; padding-top: 16px; padding-bottom: 16px; }
.marque { display: inline-flex; align-items: center; gap: 9px; text-decoration: none; font-family: var(--display); font-weight: 800; font-size: 1.45rem; letter-spacing: -0.03em; }
.marque i { width: 13px; height: 17px; background: var(--amber); border-radius: 2px; box-shadow: 0 0 18px rgba(255, 194, 75, .8); }
.barre nav { display: flex; gap: 6px 20px; align-items: center; flex-wrap: wrap; font-size: 0.95rem; }
.barre nav a, .barre .lien { color: var(--on-night-muted); text-decoration: none; background: none; border: 0; font: inherit; cursor: pointer; padding: 4px 0; border-bottom: 2px solid transparent; }
.barre nav a:hover, .barre .lien:hover { color: var(--on-night); border-bottom-color: var(--amber); }
.barre form { margin: 0; }
.pied { background: var(--night); color: var(--on-night-muted); font-size: 0.84rem; padding: 22px 0 30px; }

/* Portes d'entrée (inscription, connexion) : la nuit */
body.porte { background: var(--night); color: var(--on-night); }
/* Les tours restent collées en bas de l'écran, derrière le texte et la carte. */
#skyline { position: fixed; left: 0; bottom: 0; width: 100%; height: 250px; display: block; z-index: 0; pointer-events: none; }
body.porte .barre { background: transparent; position: relative; z-index: 1; }
body.porte main { position: relative; z-index: 1; padding-top: clamp(16px, 5vh, 64px); padding-bottom: 48px; }
body.porte.plein { min-height: 100vh; min-height: 100dvh; }
body.porte.plein main { padding-bottom: 24px; }
.mention { font-size: 0.82rem; color: var(--on-night-muted); max-width: 34em; }
.promesse { font-size: 1.12rem; color: var(--on-night-muted); max-width: 30em; }
body.porte .etiquette { color: var(--on-night-muted); }
body.porte h1 em { color: var(--amber); }
.porte-grille { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: 48px; align-items: center; padding-top: 16px; }
.porte-grille.etroit { grid-template-columns: minmax(0, 460px); justify-content: center; }
.porte-grille .carte h2.grand { font-size: 1.6rem; }
.accroche { display: flex; flex-direction: column; gap: 22px; }
.atouts { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; gap: 10px; color: var(--on-night-muted); }
.atouts li { padding-left: 24px; position: relative; }
.atouts li::before { content: ""; position: absolute; left: 0; top: .5em; width: 10px; height: 12px; background: var(--amber); border-radius: 2px; }

/* Cartes et formulaires */
.carte { background: var(--surface); color: var(--ink); border: 1px solid var(--line); border-radius: 16px; padding: 30px; display: flex; flex-direction: column; gap: 16px; }
body.porte .carte { border: 0; box-shadow: 0 30px 60px -20px rgba(0, 0, 0, .7); }
.carte form { display: flex; flex-direction: column; gap: 16px; }
label { display: block; font-weight: 600; font-size: 0.93rem; margin-bottom: 6px; }
input[type="text"], input[type="email"], input[type="password"], select { width: 100%; font: inherit; font-size: 1rem; padding: 12px 14px; border-radius: 8px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); }
input:focus, select:focus { border-color: var(--ink); outline: 3px solid var(--amber-soft); outline-offset: 0; }
.deux { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.coche { display: grid; grid-template-columns: 22px minmax(0, 1fr); gap: 10px; align-items: start; }
.coche input { width: 18px; height: 18px; margin: 3px 0 0; accent-color: var(--ink); }
.coche label { font-weight: 400; margin: 0; font-size: 0.93rem; }
.piege { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.sous { font-size: 0.93rem; color: var(--muted); }
.bouton { display: inline-flex; align-items: center; justify-content: center; gap: 10px; font: inherit; font-weight: 600; font-size: 1.02rem; padding: 14px 22px; border-radius: 8px; border: 0; cursor: pointer; text-decoration: none; transition: transform .15s ease; }
.bouton:hover { transform: translateY(-2px); }
.bouton.or { background: var(--amber); color: var(--night); box-shadow: 0 10px 30px -14px rgba(255, 194, 75, .9); }
.bouton.sombre { background: var(--night); color: var(--on-night); align-self: flex-start; }
.bouton.rouge { background: var(--red); color: #fff; align-self: flex-start; }
.bouton.petit-b { font-size: 0.85rem; padding: 8px 12px; margin-top: 6px; }
.erreurs { background: var(--red-soft); color: var(--red); border-left: 4px solid var(--red); border-radius: 6px; padding: 12px 16px; font-size: 0.95rem; }
.erreurs ul { margin: 0; padding-left: 18px; }
.info { background: var(--amber-soft); color: var(--ink); border-left: 4px solid var(--amber); border-radius: 6px; padding: 12px 16px; margin-bottom: 24px; font-size: 0.97rem; }
.carte .info { margin-bottom: 0; }

/* Espace : les offres */
.accueil { display: flex; justify-content: space-between; align-items: flex-end; gap: 20px 32px; flex-wrap: wrap; margin-bottom: 28px; }
.accueil > div { display: flex; flex-direction: column; gap: 12px; max-width: 40em; }
.accueil h1 em { white-space: nowrap; background: linear-gradient(transparent 62%, var(--amber) 62%); padding: 0 .08em; }
.chapo { color: var(--muted); font-size: 1.08rem; }
.filtres { display: flex; gap: 10px 14px; flex-wrap: wrap; align-items: center; background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 14px 16px; position: sticky; top: 8px; z-index: 3; }
.filtres label { margin: 0; font-size: 0.86rem; }
.filtres select { width: auto; padding: 8px 10px; }
.coche-filtre { display: inline-flex; align-items: center; gap: 8px; font-weight: 400; }
.coche-filtre input { accent-color: var(--ink); width: 16px; height: 16px; }
.compte { margin-left: auto; font-family: var(--mono); font-size: 0.8rem; color: var(--muted); }
main section { margin-top: 32px; }
main section > h2 { margin-bottom: 12px; }
.vues { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 10px; }
.vue { font: inherit; font-weight: 600; font-size: 0.95rem; padding: 10px 16px; border-radius: 99px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); cursor: pointer; display: inline-flex; align-items: center; gap: 8px; }
.vue b { font-family: var(--mono); font-size: 0.78rem; font-weight: 600; background: var(--paper); border-radius: 99px; padding: 1px 8px; }
.vue[aria-pressed="true"] { background: var(--night); color: var(--on-night); border-color: var(--night); }
.vue[aria-pressed="true"] b { background: var(--amber); color: var(--night); }
.avancement { font-family: var(--mono); font-size: 0.8rem; color: var(--muted); min-height: 1.4em; margin-bottom: 12px; white-space: pre-wrap; }
.vide { background: var(--surface); border: 1px dashed var(--line); border-radius: 14px; padding: 28px; margin-top: 20px; color: var(--muted); text-align: center; }
.offres { list-style: none; margin: 0; padding: 0; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; overflow: hidden; }
.offres li { display: grid; grid-template-columns: 34px 124px minmax(0, 1fr) auto; gap: 6px 14px; padding: 14px 18px 14px 10px; border-bottom: 1px solid var(--line); align-items: center; font-size: 0.95rem; border-left: 4px solid transparent; }
.offres li:last-child { border-bottom: 0; }
.offres li[hidden] { display: none; }
.offres li[data-fav="1"] { border-left-color: var(--amber); }
.offres li[data-statut]:not([data-statut=""]) { background: linear-gradient(90deg, var(--amber-soft), var(--surface) 38%); }
.offres li[data-statut="refus"] { background: var(--surface); }
.offres li[data-statut="refus"] .poste, .offres li[data-statut="refus"] .cab { color: var(--muted); }
.etoile { font-size: 1.35rem; line-height: 1; background: none; border: 0; cursor: pointer; color: var(--line); padding: 4px; border-radius: 6px; }
.etoile:hover { color: var(--muted); }
.etoile[aria-pressed="true"] { color: var(--amber); text-shadow: 0 0 0.5px var(--ink); -webkit-text-stroke: 0.6px #8A6200; }
.offres .cab { font-weight: 700; }
.offres .ville { display: block; font-size: 0.84rem; color: var(--muted); }
.offres .actions { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; justify-content: flex-end; }
.offres select.statut { width: auto; font-size: 0.86rem; padding: 7px 8px; border-radius: 8px; }
.offres li[data-statut]:not([data-statut=""]) select.statut { border-color: var(--ink); font-weight: 600; }
.plus { font: inherit; font-size: 0.86rem; background: none; border: 0; color: var(--muted); cursor: pointer; text-decoration: underline; text-underline-offset: 3px; padding: 4px 0; }
.offres .voir { font-weight: 600; font-size: 0.9rem; text-underline-offset: 3px; white-space: nowrap; }
.details { grid-column: 2 / -1; display: grid; grid-template-columns: 190px minmax(0, 1fr) auto; gap: 12px 16px; align-items: end; padding: 10px 0 4px; }
.details[hidden] { display: none; }
.details label { font-size: 0.82rem; }
.details input[type="date"], .details textarea { width: 100%; font: inherit; font-size: 0.93rem; padding: 9px 10px; border-radius: 8px; border: 1.5px solid var(--line); background: var(--surface); color: var(--ink); }
.details textarea { resize: vertical; min-height: 44px; }
.etat { grid-column: 2 / -1; font-family: var(--mono); font-size: 0.76rem; color: var(--muted); }
.etat:empty { display: none; }
.etat.ok { color: #1B6B3A; }
.etat.ko { color: var(--red); }
.pastille { display: inline-block; font-family: var(--mono); font-size: 0.66rem; font-weight: 600; background: var(--amber); color: var(--night); padding: 1px 6px; border-radius: 4px; vertical-align: 2px; }
.pastille.clair { background: var(--amber-soft); }

/* Compte, administration */
.blocs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; margin-top: 24px; align-items: start; }
.fiche { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 8px 14px; margin: 0; font-size: 0.97rem; }
.fiche dt { color: var(--muted); font-size: 0.86rem; padding-top: 2px; }
.fiche dd { margin: 0; overflow-wrap: anywhere; }
.carte.danger { border-color: var(--red); }
.carte.danger h2 { color: var(--red); }
.defile { overflow-x: auto; background: var(--surface); border: 1px solid var(--line); border-radius: 14px; }
.inscrits { width: 100%; border-collapse: collapse; font-size: 0.9rem; }
.inscrits th { text-align: left; font-family: var(--mono); font-size: 0.72rem; font-weight: 500; letter-spacing: 0.05em; text-transform: uppercase; background: var(--night); color: var(--on-night); padding: 11px 12px; white-space: nowrap; }
.inscrits td { padding: 11px 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.inscrits summary { cursor: pointer; color: var(--red); font-size: 0.86rem; }

@media (max-width: 860px) {
  body.plein .promesse, body.plein .atouts { display: none; }
  body.plein h1 { font-size: 1.9rem; }
  body.plein .accroche { gap: 12px; }
  body.plein .porte-grille { gap: 20px; }
  .porte-grille, .blocs { grid-template-columns: minmax(0, 1fr); gap: 28px; }
  .offres li { grid-template-columns: 34px minmax(0, 1fr); }
  .offres .cab { grid-column: 2; }
  .offres .poste, .offres .actions { grid-column: 2; }
  .offres .actions { justify-content: flex-start; }
  .details { grid-template-columns: minmax(0, 1fr); }
  .compte { margin-left: 0; width: 100%; }
  .filtres { position: static; }
}
@media (max-width: 520px) {
  body { font-size: 16px; }
  .cadre { padding-left: 16px; padding-right: 16px; }
  .carte { padding: 22px; }
  .deux { grid-template-columns: minmax(0, 1fr); }
  .bouton { width: 100%; }
}
@media (prefers-reduced-motion: reduce) { .bouton { transition: none; } }
