/* ========================================================================
   METOD · Frontend Architecte
   Design system v3.2 — Unified METOD brand identity
   Tokens imported from metod-tokens.css
   ======================================================================== */

/* ---------- Tokens (legacy aliases for backward compat) ---------- */
:root {
  /* Neutral palette — mapped to METOD tokens */
  --cream: var(--metod-bone);
  --cream-warm: var(--metod-paper);
  --paper: #FFFFFF;
  --ink: var(--metod-ink);
  --ink-70: rgba(10, 10, 10, 0.72);
  --ink-55: var(--metod-ash);
  --ink-40: var(--metod-stone);
  --ink-25: rgba(10, 10, 10, 0.22);
  --ink-10: rgba(10, 10, 10, 0.10);
  --ink-06: rgba(10, 10, 10, 0.06);

  /* Accent — METOD orange (same as commune platform) */
  --accent: var(--metod-orange);
  --accent-hover: var(--metod-orange-deep);
  --accent-soft: var(--metod-orange-glow);
  --accent-light: rgba(232, 90, 16, 0.12);

  /* Semantic status colors — warm tones */
  --status-red: var(--metod-brick);
  --status-orange: var(--metod-caramel);
  --status-yellow: var(--metod-caramel);
  --status-green: var(--metod-forest);

  --status-red-bg: var(--metod-brick-soft);
  --status-orange-bg: var(--metod-caramel-soft);
  --status-yellow-bg: var(--metod-caramel-soft);
  --status-green-bg: var(--metod-forest-soft);

  /* Typography — General Sans (Fontshare) */
  --font-ui: var(--font-body);
  --font-mono: 'JetBrains Mono', 'SF Mono', Menlo, monospace;
  --font-editorial: var(--font-display);

  /* Geometry — METOD token values */
  --rail: 72px;
  --nav-height: var(--shell-topbar-height);
  --radius: var(--radius-sm);
  --hairline: var(--border-hairline);
  --hairline-strong: var(--border-soft);
}


/* Grain texture overlay */
body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9999;
  opacity: 0.025;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 256px 256px;
}

button {
  font-family: inherit;
  cursor: pointer;
  border: 0;
  background: transparent;
  color: inherit;
}


/* ---------- Layout principal (sidebar + contenu) ---------- */
.app {
  display: grid;
  grid-template-columns: var(--rail) 1fr;
  min-height: 100vh;
}

/* ---------- Sidebar ---------- */
.rail {
  background: var(--metod-bone);
  border-right: var(--border-hairline);
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: var(--space-5) 0;
  position: sticky;
  top: 0;
  height: calc(100vh / 1.08);
}
.rail__brand {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  margin-bottom: var(--space-8);
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 26px;
  color: var(--metod-ink);
  letter-spacing: -0.04em;
}
.rail__nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  flex: 1;
}
.rail__link {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 48px;
  height: 48px;
  color: var(--metod-ash);
  border-radius: var(--radius-sm);
  position: relative;
  transition: color var(--duration-fast) var(--ease-out), background var(--duration-fast) var(--ease-out);
}
.rail__link:hover { color: var(--metod-ink); background: rgba(10, 10, 10, 0.06); }
.rail__link.is-active { color: var(--metod-orange); }
.rail__link.is-active::before {
  content: "";
  position: absolute;
  left: -20px;
  top: 50%;
  transform: translateY(-50%);
  width: 3px;
  height: 20px;
  background: var(--metod-orange);
  border-radius: 0 2px 2px 0;
}
.rail__link svg { width: 20px; height: 20px; stroke: currentColor; }
.rail__label {
  font-size: var(--font-size-caption);
  font-weight: 500;
  margin-top: var(--space-1);
  letter-spacing: 0.02em;
  font-size: 10px;
}
.rail__foot {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--metod-orange);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: var(--font-size-caption);
  letter-spacing: 0.04em;
}

/* ---------- Top bar ---------- */
.topbar {
  height: var(--shell-topbar-height);
  border-bottom: var(--border-hairline);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-8);
  background: var(--metod-bone);
  position: sticky;
  top: 0;
  z-index: 10;
}
.topbar__left {
  display: flex;
  align-items: baseline;
  gap: var(--space-4);
}
.topbar__commune {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: 18px;
  color: var(--metod-ink);
  letter-spacing: -0.02em;
}
.topbar__breadcrumb {
  font-size: 13px;
  color: var(--metod-ash);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.topbar__breadcrumb .sep { opacity: 0.4; }
.topbar__right {
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.search {
  position: relative;
  display: flex;
  align-items: center;
}
.search__input {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-sm);
  padding: var(--space-2) var(--space-3) var(--space-2) 34px;
  font-size: 13px;
  color: var(--metod-ink);
  width: 260px;
  height: 36px;
  transition: border-color var(--duration-fast) var(--ease-out);
}
.search__input:focus-visible { border-color: var(--metod-orange); outline: 0; box-shadow: 0 0 0 3px rgba(232, 90, 16, 0.12); }
.search__input::placeholder { color: var(--metod-stone); }
.search__icon {
  position: absolute;
  left: 10px;
  width: 16px;
  height: 16px;
  color: var(--metod-stone);
  pointer-events: none;
}
.bell {
  width: 36px;
  height: 36px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  position: relative;
  color: var(--ink-70);
}
.bell:hover { background: rgba(10, 10, 10, 0.06); }
.bell .badge {
  position: absolute;
  top: 6px;
  right: 6px;
  min-width: 16px;
  height: 16px;
  border-radius: 8px;
  background: var(--metod-brick);
  color: var(--paper);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 var(--space-1);
}

/* ---------- Notification dropdown ---------- */
.notif-dropdown {
  position: absolute;
  top: 44px;
  right: 0;
  width: 380px;
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl);
  z-index: 100;
  display: none;
  overflow: hidden;
}
.notif-dropdown.is-open { display: block; }
.notif-dropdown__header {
  padding: var(--space-4) var(--space-5);
  border-bottom: var(--border-hairline);
  font-size: 13px;
  font-weight: 600;
  color: var(--metod-ink);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.notif-dropdown__item {
  padding: var(--space-3) var(--space-5);
  border-bottom: var(--border-hairline);
  display: flex;
  gap: var(--space-3);
  align-items: flex-start;
  transition: background var(--duration-fast) var(--ease-out);
  cursor: pointer;
}
.notif-dropdown__item:hover { background: var(--metod-paper); }
.notif-dropdown__item:last-of-type { border-bottom: 0; }
.notif-dropdown__dot {
  width: 8px;
  height: 8px;
  border-radius: var(--radius-full);
  flex-shrink: 0;
  margin-top: 5px;
}
.notif-dropdown__dot--orange { background: var(--metod-caramel); }
.notif-dropdown__dot--green { background: var(--metod-forest); }
.notif-dropdown__dot--red { background: var(--metod-brick); }
.notif-dropdown__dot--blue { background: var(--metod-slate); }
.notif-dropdown__text {
  font-size: 13px;
  color: var(--metod-ink);
  line-height: 1.4;
  flex: 1;
}
.notif-dropdown__text strong { font-weight: 600; }
.notif-dropdown__time {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-stone);
  flex-shrink: 0;
  margin-top: 2px;
}
.notif-dropdown__footer {
  padding: var(--space-3) var(--space-5);
  border-top: var(--border-hairline);
  text-align: center;
}
.notif-dropdown__footer a {
  font-size: var(--font-size-caption);
  color: var(--metod-orange);
  font-weight: 600;
  cursor: pointer;
}
.notif-dropdown__footer a:hover { text-decoration: underline; }
.notif-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99;
  display: none;
}
.notif-backdrop.is-open { display: block; }

/* ---------- PRO badge ---------- */
.pro-badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--metod-orange-glow);
  color: var(--metod-orange);
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

/* ---------- Conformity check ---------- */
.conformity-summary {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-4) var(--space-5);
  background: var(--metod-paper);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-5);
}
.conformity-counter {
  font-family: var(--font-mono);
  font-size: var(--font-size-h3);
  font-weight: 600;
}

/* ---------- PDF received cards ---------- */
.pdf-card {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-4) var(--space-5);
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-3);
  transition: background var(--duration-fast) var(--ease-out);
}
.pdf-card:hover { background: var(--metod-paper); }
.pdf-card__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-sm);
  background: var(--metod-brick-soft);
  color: var(--metod-brick);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.pdf-card__info { flex: 1; }
.pdf-card__name {
  font-size: 13px;
  font-weight: 600;
  color: var(--metod-ink);
  font-family: var(--font-mono);
}
.pdf-card__date {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  margin-top: 2px;
}
.pdf-card__action {
  color: var(--metod-ash);
  cursor: pointer;
  flex-shrink: 0;
}
.pdf-card__action:hover { color: var(--metod-ink); }

/* ---------- Authorization banner ---------- */
.auth-banner {
  display: flex;
  align-items: center;
  gap: var(--space-4);
  padding: var(--space-5) var(--space-6);
  background: var(--metod-forest-soft);
  border: 1px solid var(--metod-forest);
  border-radius: var(--radius-md);
  margin-bottom: var(--space-6);
}
.auth-banner__icon {
  width: 40px;
  height: 40px;
  border-radius: var(--radius-full);
  background: var(--metod-forest);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.auth-banner__text {
  flex: 1;
}
.auth-banner__title {
  font-size: 16px;
  font-weight: 600;
  color: var(--metod-forest);
}
.auth-banner__sub {
  font-size: 13px;
  color: var(--metod-ash);
  margin-top: 2px;
}

/* ---------- Mode toggle ---------- */
.mode-toggle {
  display: flex;
  background: var(--metod-paper);
  border-radius: var(--radius-md);
  padding: 3px;
  margin-bottom: var(--space-6);
  border: var(--border-hairline);
}
.mode-toggle__btn {
  flex: 1;
  padding: var(--space-2) var(--space-4);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
  color: var(--metod-ash);
  text-align: center;
  cursor: pointer;
  transition: all var(--duration-fast) var(--ease-out);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
}
.mode-toggle__btn.is-active {
  background: var(--paper);
  color: var(--metod-ink);
  box-shadow: var(--shadow-sm);
}
.mode-toggle__btn:hover:not(.is-active) { color: var(--metod-ink); }

/* ---------- Faisabilite page ---------- */
.faisabilite-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-6);
}
.faisabilite-header__title {
  font-family: var(--font-display);
  font-size: var(--font-size-h2);
  font-weight: 500;
  letter-spacing: -0.015em;
  color: var(--metod-ink);
}
.faisabilite-header__sub {
  font-size: 14px;
  color: var(--metod-ash);
  margin-top: var(--space-2);
  max-width: 600px;
}
.faisabilite-results-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-6);
}

/* ---------- OAI step ---------- */
.oai-card {
  background: var(--metod-forest-soft);
  border: 1px solid var(--metod-forest);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  display: flex;
  align-items: center;
  gap: var(--space-4);
  margin-bottom: var(--space-5);
}
.oai-card--warning {
  background: var(--metod-caramel-soft);
  border-color: var(--metod-caramel);
}

/* ---------- Pro automation card ---------- */
.auto-card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin-bottom: var(--space-3);
  display: flex;
  align-items: center;
  gap: var(--space-4);
}
.auto-card__info { flex: 1; }
.auto-card__title {
  font-size: 14px;
  font-weight: 600;
  color: var(--metod-ink);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.auto-card__desc {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  margin-top: 2px;
}
.agent {
  display: flex;
  align-items: center;
  gap: 10px;
  padding-left: var(--space-4);
  border-left: var(--border-hairline);
}
.agent__name {
  font-size: 13px;
  font-weight: 600;
  color: var(--metod-ink);
  line-height: 1.1;
}
.agent__role {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  line-height: 1.1;
  margin-top: 2px;
}
.agent__avatar {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  background: var(--metod-orange);
  color: var(--paper);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 600;
  font-size: var(--font-size-caption);
}

/* ---------- Contenu page (aligné sur .dash du shared) ---------- */
.page {
  padding: var(--space-10) var(--space-8) var(--space-12);
  max-width: none;
  flex: 1;
}
/* .page__head / __eyebrow / __title / __subtitle → unifiés dans metod_shared.css */


/* ---------- Bandeaux de synthese ---------- */
.synthese {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}
.synthese__cell {
  padding: var(--space-6) var(--space-8);
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  display: flex;
  flex-direction: column;
  gap: var(--space-2);
  cursor: pointer;
  transition: background var(--duration-fast) var(--ease-out);
  position: relative;
}
.synthese__cell:hover { background: var(--metod-paper); }
.synthese__cell.is-active {
  background: var(--metod-ink);
  color: var(--paper);
}
.synthese__cell.is-active .synthese__label,
.synthese__cell.is-active .synthese__hint { color: var(--paper); opacity: 0.8; }
.synthese__label {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.12em;
  color: var(--metod-ash);
  display: flex;
  align-items: center;
  gap: var(--space-2);
}
.synthese__label .dot {
  width: 6px;
  height: 6px;
  border-radius: var(--radius-full);
}
.synthese__label .dot--red { background: var(--metod-brick); }
.synthese__label .dot--orange { background: var(--metod-caramel); }
.synthese__label .dot--yellow { background: var(--metod-caramel); }
.synthese__label .dot--green { background: var(--metod-forest); }
.synthese__label .dot--blue { background: var(--metod-orange); }
.synthese__value {
  font-family: var(--font-mono);
  font-size: 44px;
  font-weight: 400;
  line-height: 1;
  letter-spacing: -0.04em;
  color: var(--metod-ink);
}
.synthese__cell.is-active .synthese__value { color: var(--paper); }
.synthese__hint {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  font-family: var(--font-mono);
}

/* ---------- Cards ---------- */
.card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  width: 100%;
  overflow-x: auto;
}
.card__head {
  padding: var(--space-4) var(--space-6);
  border-bottom: var(--border-hairline);
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.card__title {
  font-size: 13px;
  font-weight: 600;
  letter-spacing: 0.02em;
}
.card__meta {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
}

/* ---------- Project cards grid ---------- */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(380px, 1fr));
  gap: var(--space-4);
  margin-bottom: var(--space-8);
}
.project-card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  transition: border-color var(--duration-fast) var(--ease-out), box-shadow var(--duration-fast) var(--ease-out);
  cursor: pointer;
}
.project-card:hover {
  border-color: var(--metod-fog);
  box-shadow: var(--shadow-md);
}
.project-card__header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
}
.project-card__ref {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  margin-bottom: var(--space-1);
}
.project-card__name {
  font-size: var(--font-size-body);
  font-weight: 600;
  color: var(--metod-ink);
  line-height: 1.3;
}
.project-card__address {
  font-size: 13px;
  color: var(--ink-70);
  margin-top: 2px;
}
.project-card__meta {
  display: flex;
  gap: var(--space-4);
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
}
.project-card__meta span {
  display: flex;
  align-items: center;
  gap: var(--space-1);
}
.project-card__progress {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.project-card__progress-label {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  font-weight: 500;
}
.project-card__progress-bar {
  height: 4px;
  background: rgba(10, 10, 10, 0.06);
  border-radius: 2px;
  overflow: hidden;
}
.project-card__progress-fill {
  height: 100%;
  background: var(--metod-orange);
  border-radius: 2px;
  transition: width 300ms var(--ease-out);
}
.project-card__progress-fill--green { background: var(--metod-forest); }
.project-card__progress-fill--orange { background: var(--metod-caramel); }
.project-card__progress-fill--red { background: var(--metod-brick); }
.project-card__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-top: var(--space-3);
  border-top: var(--border-hairline);
}
.project-card__date {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-stone);
}
.project-card__actions {
  display: flex;
  gap: 6px;
}


/* ---------- Tabs ---------- */
.tabs {
  display: flex;
  border-bottom: var(--border-hairline);
  padding: 0 var(--space-8);
  background: var(--metod-bone);
}
.tabs__item {
  padding: var(--space-4) 0;
  margin-right: var(--space-8);
  font-size: 13px;
  font-weight: 500;
  color: var(--metod-ash);
  position: relative;
  white-space: nowrap;
  display: flex;
  align-items: center;
  gap: var(--space-2);
  cursor: pointer;
}
.tabs__item:hover { color: var(--metod-ink); }
.tabs__item.is-active {
  color: var(--metod-orange);
  font-weight: 600;
}
.tabs__item.is-active::after {
  content: "";
  position: absolute;
  bottom: -1px;
  left: 0;
  right: 0;
  height: 3px;
  background: var(--metod-orange);
  border-radius: 2px 2px 0 0;
}
.tabs__item .count {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  background: rgba(10, 10, 10, 0.06);
  color: var(--ink-70);
  padding: 2px 6px;
  border-radius: var(--radius-full);
  min-width: 20px;
  text-align: center;
  font-weight: 600;
}
.tab-panel { display: none; padding: var(--space-8); }
.tab-panel.is-active { display: block; }

/* ---------- Progress stepper ---------- */
.stepper {
  display: flex;
  align-items: flex-start;
  gap: 0;
  margin: var(--space-6) 0;
}
.stepper__step {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
}
.stepper__step:not(:last-child)::after {
  content: "";
  position: absolute;
  top: 14px;
  left: calc(50% + 16px);
  right: calc(-50% + 16px);
  height: 2px;
  background: var(--metod-mist);
}
.stepper__step.is-done:not(:last-child)::after {
  background: var(--metod-orange);
}
.stepper__step.is-active:not(:last-child)::after {
  background: linear-gradient(90deg, var(--metod-orange) 50%, var(--metod-mist) 50%);
}
.stepper__dot {
  width: 28px;
  height: 28px;
  border-radius: var(--radius-full);
  background: var(--paper);
  border: 2px solid var(--metod-mist);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  font-weight: 600;
  color: var(--metod-stone);
  position: relative;
  z-index: 1;
  transition: all var(--duration-base) var(--ease-out);
}
.stepper__step.is-done .stepper__dot {
  background: var(--metod-orange);
  border-color: var(--metod-orange);
  color: var(--paper);
}
.stepper__step.is-active .stepper__dot {
  border-color: var(--metod-orange);
  color: var(--metod-orange);
  box-shadow: 0 0 0 4px var(--metod-orange-glow);
}
.stepper__label {
  font-size: var(--font-size-eyebrow);
  font-weight: 500;
  color: var(--metod-ash);
  margin-top: var(--space-2);
  max-width: 100px;
  line-height: 1.3;
}
.stepper__step.is-done .stepper__label { color: var(--metod-ink); }
.stepper__step.is-active .stepper__label { color: var(--metod-orange); font-weight: 600; }

/* ---------- Feasibility cards ---------- */
.feasibility-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: var(--space-3);
  margin: var(--space-5) 0;
}
.feasibility-card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-4);
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
}
.feasibility-card__label {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  font-weight: 500;
}
.feasibility-card__value {
  font-family: var(--font-mono);
  font-size: var(--font-size-h3);
  font-weight: 500;
  color: var(--metod-ink);
  letter-spacing: -0.02em;
}
.feasibility-card__source {
  font-size: 10px;
  color: var(--metod-stone);
  font-family: var(--font-mono);
}

/* ---------- Remarks/retours ---------- */
.remark {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-5) var(--space-6);
  margin-bottom: var(--space-3);
}
.remark__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 10px;
}
.remark__number {
  font-family: var(--font-mono);
  font-size: var(--font-size-caption);
  font-weight: 600;
  color: var(--metod-orange);
  background: var(--metod-orange-glow);
  padding: 2px var(--space-2);
  border-radius: var(--radius-full);
}
.remark__plan-ref {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
}
.remark__text {
  font-size: 14px;
  color: var(--ink-70);
  line-height: 1.6;
  margin-bottom: var(--space-3);
}
.remark__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.remark__date {
  font-family: var(--font-mono);
  font-size: var(--font-size-eyebrow);
  color: var(--metod-stone);
}
.remark__status-select {
  padding: var(--space-1) 10px;
  border: var(--border-hairline);
  border-radius: var(--radius-sm);
  font-size: var(--font-size-caption);
  font-weight: 500;
  background: var(--paper);
}

/* ---------- Document list ---------- */
.doc-list {
  list-style: none;
  padding: 0;
  margin: 0;
}
.doc-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: 14px 0;
  border-bottom: var(--border-hairline);
}
.doc-item:last-child { border-bottom: 0; }
.doc-item__icon {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  background: rgba(10, 10, 10, 0.06);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--metod-ash);
  flex-shrink: 0;
}
.doc-item__info { flex: 1; }
.doc-item__name {
  font-size: 13px;
  font-weight: 500;
  color: var(--metod-ink);
}
.doc-item__meta {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
  margin-top: 2px;
  font-family: var(--font-mono);
}
.doc-item__status {
  flex-shrink: 0;
}

/* ---------- Institution cards ---------- */
.institution-card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  margin-bottom: var(--space-3);
}
.institution-card__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: var(--space-4);
}
.institution-card__name {
  font-size: var(--font-size-body);
  font-weight: 600;
  color: var(--metod-ink);
}
.institution-card__desc {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  margin-top: 2px;
}
.institution-card__meta {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: var(--space-4);
  padding-top: var(--space-4);
  border-top: var(--border-hairline);
}
.institution-card__meta-item {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-ash);
}
.institution-card__meta-item strong {
  display: block;
  color: var(--metod-ink);
  font-family: var(--font-mono);
  font-size: var(--font-size-mono);
  font-weight: 500;
  margin-top: var(--space-1);
}

/* ---------- Form sections ---------- */
.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0;
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  overflow: hidden;
}
.form-section {
  padding: var(--space-6) var(--space-8);
  border-right: var(--border-hairline);
  border-bottom: var(--border-hairline);
}
.form-section:nth-child(2n) { border-right: 0; }
.form-section--full {
  grid-column: 1 / -1;
  border-right: 0;
}
.form-section__title {
  font-family: var(--font-mono);
  font-size: 11.5px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--metod-orange);
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-2);
  border-bottom: var(--border-hairline);
}
.form-field {
  display: grid;
  grid-template-columns: 140px 1fr;
  gap: var(--space-4);
  padding: var(--space-2) 0;
  font-size: 13px;
  align-items: baseline;
}
.form-field__label {
  color: var(--metod-ash);
  font-size: var(--font-size-caption);
}
.form-field__value {
  color: var(--metod-ink);
  font-weight: 500;
}
.form-field__value.mono { font-family: var(--font-mono); }

/* ---------- Input fields ---------- */
.input-field {
  width: 100%;
  padding: 10px 14px;
  border: var(--border-hairline);
  border-radius: var(--radius-sm);
  font-size: 14px;
  background: var(--paper);
  transition: border-color var(--duration-fast) var(--ease-out);
}
.input-field:focus {
  border-color: var(--metod-orange);
  outline: none;
  box-shadow: 0 0 0 3px var(--metod-orange-glow);
}
.select-field {
  width: 100%;
  padding: 10px 14px;
  border: var(--border-hairline);
  border-radius: var(--radius-sm);
  font-size: 14px;
  background: var(--paper);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg width='12' height='8' viewBox='0 0 12 8' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M1 1.5L6 6.5L11 1.5' stroke='%230A0A0A' stroke-width='1.5' stroke-linecap='round'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 36px;
}
.textarea-field {
  width: 100%;
  padding: 10px 14px;
  border: var(--border-hairline);
  border-radius: var(--radius-sm);
  font-size: 14px;
  background: var(--paper);
  min-height: 100px;
  resize: vertical;
}
.textarea-field:focus,
.select-field:focus {
  border-color: var(--metod-orange);
  outline: none;
  box-shadow: 0 0 0 3px var(--metod-orange-glow);
}
.field-group {
  margin-bottom: var(--space-5);
}
.field-label {
  display: block;
  font-size: var(--font-size-caption);
  font-weight: 600;
  color: var(--ink-70);
  margin-bottom: 6px;
}
.field-hint {
  font-size: var(--font-size-eyebrow);
  color: var(--metod-stone);
  margin-top: var(--space-1);
}

/* ---------- Wizard stepper ---------- */
.wizard {
  max-width: var(--shell-content-max);
}
.wizard__steps {
  display: flex;
  gap: 0;
  margin-bottom: var(--space-10);
  padding: 0 var(--space-5);
}
.wizard__step {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  position: relative;
}
.wizard__step:not(:last-child)::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--metod-mist);
  margin-left: 10px;
}
.wizard__step.is-done:not(:last-child)::after {
  background: var(--metod-orange);
}
.wizard__step-num {
  width: 32px;
  height: 32px;
  border-radius: var(--radius-full);
  border: 2px solid var(--metod-mist);
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-mono);
  font-size: var(--font-size-caption);
  font-weight: 600;
  color: var(--metod-stone);
  flex-shrink: 0;
}
.wizard__step.is-done .wizard__step-num {
  background: var(--metod-orange);
  border-color: var(--metod-orange);
  color: var(--paper);
}
.wizard__step.is-active .wizard__step-num {
  border-color: var(--metod-orange);
  color: var(--metod-orange);
}
.wizard__step-label {
  font-size: var(--font-size-caption);
  font-weight: 500;
  color: var(--metod-ash);
  white-space: nowrap;
}
.wizard__step.is-done .wizard__step-label,
.wizard__step.is-active .wizard__step-label {
  color: var(--metod-ink);
}
.wizard__card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-lg);
  padding: var(--space-10);
}
.wizard__card-title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--font-size-h3);
  color: var(--metod-ink);
  letter-spacing: -0.01em;
  margin-bottom: var(--space-2);
}
.wizard__card-desc {
  font-size: 13px;
  color: var(--metod-ash);
  margin-bottom: var(--space-8);
}
.wizard__actions {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--space-8);
  padding-top: var(--space-6);
  border-top: var(--border-hairline);
}


/* ---------- Rule rows ---------- */
.rule {
  display: grid;
  grid-template-columns: 24px 1fr 120px 120px 100px;
  gap: var(--space-4);
  align-items: center;
  padding: var(--space-4) var(--space-6);
  border-bottom: var(--border-hairline);
}
.rule:hover { background: var(--metod-bone); }
.rule__mark {
  width: 16px;
  height: 16px;
  border-radius: var(--radius-full);
  display: flex;
  align-items: center;
  justify-content: center;
}
.rule__mark--red { background: var(--metod-brick); }
.rule__mark--orange { background: var(--metod-caramel); }
.rule__mark--green { background: var(--metod-forest); }
.rule__name {
  font-weight: 600;
  font-size: 13px;
  color: var(--metod-ink);
}
.rule__desc {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  margin-top: 2px;
}
.rule__value, .rule__limit {
  font-family: var(--font-mono);
  font-size: var(--font-size-mono);
  color: var(--metod-ink);
  text-align: right;
}
.rule__limit { color: var(--metod-ash); }
.rule__verdict-text {
  font-size: var(--font-size-eyebrow);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  text-align: right;
}
.rule__verdict-text--conforme { color: var(--metod-forest); }
.rule__verdict-text--nonconforme { color: var(--metod-brick); }
.rule__verdict-text--averifier { color: var(--metod-caramel); }


/* ---------- Meta blocks ---------- */
.meta-block { margin-bottom: var(--space-6); }
.meta-block__label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--metod-ash);
  margin-bottom: 6px;
}
.meta-block__value {
  font-size: 14px;
  color: var(--metod-ink);
  font-weight: 500;
  line-height: 1.4;
}
.meta-block__mono {
  font-family: var(--font-mono);
  font-size: var(--font-size-mono);
}

/* ---------- Action cards ---------- */
.action-card {
  background: var(--paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  margin-bottom: var(--space-5);
}
.action-card__label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--metod-ash);
  margin-bottom: var(--space-2);
}
.action-card__title {
  font-size: var(--font-size-body);
  font-weight: 600;
  line-height: 1.3;
  margin-bottom: 14px;
  color: var(--metod-ink);
}
.action-card__hint {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  margin-top: var(--space-3);
  line-height: 1.4;
}

/* ---------- Sidebar layout for dashboard ---------- */
.dash-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 0;
  min-height: calc(100vh - var(--shell-topbar-height));
}
.dash-main { padding: var(--space-10) var(--space-8) var(--space-12); }
.dash-sidebar {
  border-left: var(--border-hairline);
  background: var(--metod-bone);
  padding: var(--space-8) var(--space-6);
}
.dash-sidebar__section {
  margin-bottom: var(--space-8);
}
.dash-sidebar__label {
  font-family: var(--font-mono);
  font-size: 10px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  color: var(--metod-ash);
  margin-bottom: var(--space-3);
}
.dash-sidebar__link {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px var(--space-3);
  font-size: 13px;
  color: var(--ink-70);
  border-radius: var(--radius-sm);
}
.dash-sidebar__link:hover {
  background: var(--paper);
  color: var(--metod-ink);
}
.dash-sidebar__link svg { width: 16px; height: 16px; stroke: currentColor; flex-shrink: 0; }

/* ---------- Project detail layout ---------- */
.projet-layout {
  display: grid;
  grid-template-columns: 300px 1fr;
  gap: 0;
  min-height: calc(100vh - var(--shell-topbar-height));
  background: var(--paper);
  border-top: var(--border-hairline);
}
.projet-aside {
  padding: var(--space-8) var(--space-6);
  border-right: var(--border-hairline);
  background: var(--metod-bone);
  overflow-y: auto;
}
.projet-main {
  display: flex;
  flex-direction: column;
  background: var(--paper);
}

/* ---------- 3D placeholder ---------- */
.viewer-placeholder {
  width: 100%;
  height: 280px;
  background: var(--metod-paper);
  border: var(--border-hairline);
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: var(--space-2);
  color: var(--metod-stone);
  font-size: 13px;
}
.viewer-placeholder svg { opacity: 0.4; }

/* ---------- Avis services ---------- */
.avis-card {
  background: var(--paper);
  border: var(--border-hairline);
  padding: var(--space-5) var(--space-6);
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: var(--space-6);
  align-items: center;
  margin-bottom: var(--space-3);
  border-radius: var(--radius-md);
}
.avis-card__service {
  font-size: 14px;
  font-weight: 600;
  color: var(--metod-ink);
  margin-bottom: var(--space-1);
}
.avis-card__desc {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
}
.avis-card__timing {
  font-family: var(--font-mono);
  font-size: var(--font-size-caption);
  color: var(--ink-70);
  text-align: right;
}

.panel {
  background: var(--paper);
  border: var(--border-hairline);
  padding: var(--space-8) var(--space-8);
  margin-bottom: var(--space-6);
  border-radius: var(--radius-md);
}
.panel__title {
  font-family: var(--font-display);
  font-weight: 500;
  font-size: var(--font-size-h3);
  color: var(--metod-ink);
  letter-spacing: -0.01em;
  margin-bottom: var(--space-1);
}
.panel__subtitle {
  font-size: var(--font-size-caption);
  color: var(--metod-ash);
  margin-bottom: var(--space-5);
}

/* ---------- Upload zone ---------- */
.upload-zone {
  border: 2px dashed var(--metod-mist);
  border-radius: var(--radius-md);
  padding: var(--space-8);
  text-align: center;
  color: var(--metod-stone);
  font-size: 13px;
  cursor: pointer;
  transition: border-color var(--duration-fast) var(--ease-out), background var(--duration-fast) var(--ease-out);
}
.upload-zone:hover {
  border-color: var(--metod-orange);
  background: var(--metod-orange-glow);
  color: var(--metod-orange);
}

/* ---------- Checklist ---------- */
.checklist {
  list-style: none;
  padding: 0;
  margin: 0;
}
.checklist__item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  padding: var(--space-3) 0;
  border-bottom: var(--border-hairline);
  font-size: 13px;
}
.checklist__item:last-child { border-bottom: 0; }
.checklist__check {
  width: 20px;
  height: 20px;
  border-radius: var(--radius-full);
  border: 2px solid var(--metod-mist);
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}
.checklist__check.is-done {
  background: var(--metod-forest);
  border-color: var(--metod-forest);
  color: var(--paper);
}
.checklist__check.is-missing {
  border-color: var(--metod-caramel);
}

/* ---------- Empty state ---------- */
.empty-state {
  text-align: center;
  padding: var(--space-16) var(--space-8);
  color: var(--metod-stone);
}
.empty-state__icon {
  margin-bottom: var(--space-4);
  opacity: 0.4;
}
.empty-state__title {
  font-size: 16px;
  font-weight: 600;
  color: var(--metod-ash);
  margin-bottom: var(--space-2);
}
.empty-state__desc {
  font-size: 13px;
  max-width: 400px;
  margin: 0 auto;
}


/* =====================================================================
   FAISABILITE · keyframes (from faisabilite.html inline <style>)
   ===================================================================== */
@keyframes loading {
  0% { transform: translateX(-100%); }
  50% { transform: translateX(100%); }
  100% { transform: translateX(-100%); }
}

