/* =========================================================
   Prismalight — feuille de style
   Grille inspirée des plans d'architecte : 12 colonnes,
   filets fins, légendes techniques en marge.
   Palette monochrome volontaire (site clair, sections sombres).
   ========================================================= */

:root {
  --paper: #f6f6f4;
  --white: #ffffff;
  --ink: #121212;
  --graphite: #5c5c5a;
  --rule: #d9d9d5;
  --night-rule: #2e2e2e;
  --night-text: #b5b5b0;
  --night-muted: #8f8f8b;

  --f-sans: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif;
  --f-mono: "IBM Plex Mono", ui-monospace, Menlo, Consolas, monospace;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1320px;
  --header-h: 68px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 400 17px/1.6 var(--f-sans);
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; }
p, figure, h1, h2, h3, ul, ol, dl, dd { margin: 0; }
h1, h2, h3 { font-weight: 300; text-wrap: balance; letter-spacing: -0.01em; }
:focus-visible { outline: 2px solid currentColor; outline-offset: 3px; }
[hidden] { display: none !important; }

.skip { position: absolute; left: -9999px; top: 0; }
.skip:focus { left: var(--gutter); top: 8px; background: var(--ink); color: var(--paper); padding: 8px 12px; z-index: 100; }

.wrap { max-width: var(--max); margin: 0 auto; padding-inline: var(--gutter); }
.mono { font: 400 11px/1.4 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); }
.grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; }

/* ---------- En-tête ---------- */
.top {
  position: sticky; top: env(safe-area-inset-top, 0px); z-index: 20;
  background: rgba(246, 246, 244, 0.94);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--rule);
}
.top .wrap { display: flex; align-items: center; justify-content: space-between; gap: 24px; height: var(--header-h); }
.brand { display: block; line-height: 0; }
.brand img { height: 12px; width: auto; }
.nav { display: flex; gap: clamp(18px, 2.4vw, 36px); }
.nav a { font-size: 14px; text-decoration: none; color: var(--graphite); transition: color 0.2s; }
.nav a:hover, .nav a[aria-current="page"] { color: var(--ink); }
.nav a[aria-current="page"] { text-decoration: underline; text-underline-offset: 6px; text-decoration-thickness: 1px; }
.nav .cta { color: var(--ink); border-bottom: 1px solid var(--ink); padding-bottom: 2px; }
.nav .cta[aria-current="page"] { text-decoration: none; }
.menu-btn { display: none; background: none; border: 0; font: 500 13px var(--f-sans); letter-spacing: 0.08em; text-transform: uppercase; cursor: pointer; padding: 8px 0; color: var(--ink); }

/* ---------- Ouvertures de page ---------- */
.page-head { padding-block: clamp(48px, 8vw, 104px) clamp(32px, 5vw, 64px); }
.page-head .mono { display: block; margin-bottom: 20px; }
.page-head h1 { font-size: clamp(38px, 6vw, 84px); line-height: 1; max-width: 14em; }
.page-head .lede { font-size: clamp(17px, 1.6vw, 20px); color: var(--graphite); max-width: 36em; margin-top: clamp(20px, 3vw, 32px); }

.hero { padding-block: clamp(48px, 8vw, 104px) clamp(40px, 6vw, 72px); }
.hero .grid { align-items: end; }
.hero h1 { grid-column: 1 / 10; font-size: clamp(40px, 7.4vw, 104px); line-height: 0.98; }
.hero h1 em { font-style: normal; font-weight: 400; }
.hero .lede { grid-column: 1 / 7; font-size: clamp(17px, 1.6vw, 20px); color: var(--graphite); max-width: 34em; margin-top: clamp(24px, 3vw, 36px); }
.hero .curve { grid-column: 10 / 13; grid-row: 1 / 3; justify-self: end; width: min(100%, 220px); }
.audience { display: flex; flex-wrap: wrap; gap: 8px 28px; margin-top: 40px; padding-top: 20px; border-top: 1px solid var(--rule); }
.audience span { font-size: 14px; color: var(--graphite); }
.audience .mono { color: var(--ink); }

/* ---------- Photos ---------- */
.photo { display: flex; flex-direction: column; gap: 10px; min-width: 0; }
.photo img { width: 100%; object-fit: cover; background: #e4e4e1; }
.ratio-wide img { aspect-ratio: 21 / 9; }
.ratio-45 img { aspect-ratio: 4 / 5; }
.ratio-34 img { aspect-ratio: 3 / 4; }
.ratio-11 img { aspect-ratio: 1; }
.ratio-32 img { aspect-ratio: 3 / 2; }

/* ---------- Chiffres ---------- */
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 24px; }
.facts div { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--ink); padding-top: 14px; }
.facts .v { font: 300 clamp(26px, 3vw, 40px)/1 var(--f-sans); font-variant-numeric: tabular-nums; }

/* ---------- Sections ---------- */
.section { padding-block: clamp(64px, 9vw, 128px); }
.section.tight-top { padding-top: 0; }
.sec-head { margin-bottom: clamp(36px, 5vw, 64px); }
.sec-head .mono { grid-column: 1 / 4; padding-top: 10px; }
.sec-head h2 { grid-column: 4 / 12; font-size: clamp(28px, 3.6vw, 48px); line-height: 1.08; }
.sec-head .intro { grid-column: 4 / 11; color: var(--graphite); max-width: 36em; }

.link { font-size: 15px; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; align-self: flex-start; transition: opacity 0.2s; }
.link:hover { opacity: 0.6; }
.btn { display: inline-block; align-self: flex-start; background: var(--ink); color: var(--paper); text-decoration: none; font: 400 14px var(--f-sans); padding: 14px 22px; letter-spacing: 0.02em; border: 0; cursor: pointer; transition: background 0.2s; }
.btn:hover { background: #333; }
.btn:disabled { background: #777; cursor: wait; }

/* Liste d'étapes / expertises */
.steps { list-style: none; padding: 0; border-top: 1px solid var(--ink); }
.steps > li { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; padding-block: 28px; border-bottom: 1px solid var(--rule); transition: background 0.25s; }
.steps > li:hover { background: var(--white); }
.steps .n { grid-column: 1 / 2; font: 400 12px var(--f-mono); color: var(--graphite); padding-top: 8px; }
.steps h3 { grid-column: 2 / 6; font-size: clamp(22px, 2.2vw, 30px); font-weight: 400; }
.steps .body { grid-column: 6 / 12; color: var(--graphite); max-width: 36em; min-width: 0; display: flex; flex-direction: column; gap: 14px; }
.steps .deliv { font-size: 14px; color: var(--ink); }
.steps .deliv .mono { margin-right: 8px; }

.note { margin-top: 28px; }
.note p { grid-column: 6 / 12; font-size: 14px; color: var(--graphite); }

/* Encadré « ce que nous ne faisons pas » */
.boxed { border: 1px solid var(--ink); padding: clamp(20px, 3vw, 32px); display: flex; flex-direction: column; gap: 12px; max-width: 44em; }

/* ---------- Section sombre ---------- */
.dark { background: var(--ink); color: var(--paper); }
.dark .mono { color: var(--night-muted); }
.dark .intro, .dark p { color: var(--night-text); }
.types { align-items: start; }
.types .photo { grid-column: 1 / 7; }
.types .col { grid-column: 8 / 13; min-width: 0; }
.types .col .mono { display: block; margin-bottom: 16px; }
.types .intro { margin-bottom: 32px; max-width: 30em; }
.types-list { list-style: none; padding: 0; }
.types-list li { padding-block: 20px; border-bottom: 1px solid var(--night-rule); font: 300 clamp(22px, 2.4vw, 32px)/1.2 var(--f-sans); color: var(--paper); }
.types-list li:first-child { border-top: 1px solid var(--night-rule); }

.dark .spec { color: var(--paper); }
.dark .spec thead th { color: var(--night-muted); border-bottom-color: var(--paper); }
.dark .spec th, .dark .spec td { border-bottom-color: var(--night-rule); }
.dark .spec td { color: var(--night-text); }
.dark .spec td:first-child { color: var(--paper); }
.dark .spec .unit { color: var(--night-muted); }
.pillar { border-top: 1px solid var(--night-rule); padding-top: 20px; display: flex; flex-direction: column; gap: 12px; }
.pillar h3 { font-size: 22px; font-weight: 400; color: var(--paper); }

/* ---------- Showroom ---------- */
.show { align-items: center; }
.show-text { grid-column: 1 / 6; display: flex; flex-direction: column; gap: 20px; min-width: 0; }
.show-text h2 { font-size: clamp(28px, 3.6vw, 48px); line-height: 1.08; }
.show-text p { color: var(--graphite); max-width: 30em; }
.show-photos { grid-column: 7 / 13; display: grid; grid-template-columns: 3fr 2fr; gap: 16px; }
.show-photos .photo:last-child { align-self: end; }

/* ---------- Partenaires ---------- */
/* Grille centrée : la dernière ligne incomplète est centrée */
.partners { display: flex; flex-wrap: wrap; justify-content: center; list-style: none; margin: 0; padding: 0 0 1px 1px; }
.partner { flex: 0 0 25%; aspect-ratio: 3 / 2; display: flex; align-items: center; justify-content: center; border: 1px solid var(--rule); margin: 0 0 -1px -1px; background: var(--white); padding: 0; min-width: 0; position: relative; }
.partner img { max-height: 46px; width: auto; max-width: 100%; object-fit: contain; opacity: 0.85; transition: opacity 0.25s; }
.partner img.tall { max-height: 64px; }
.partner a { position: absolute; inset: 0; display: flex; align-items: center; justify-content: center; padding: 12%; transition: background 0.25s; }
.partner a:hover { background: #fbfbfa; }
.partner a:focus-visible { outline: 2px solid var(--ink); outline-offset: -4px; }
.partner:hover img { opacity: 1; }
.partners-foot { display: flex; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-top: 24px; }

/* ---------- Tableaux techniques ---------- */
.spec { width: 100%; border-collapse: collapse; font-size: 15px; }
.spec th, .spec td { text-align: left; padding: 14px 16px 14px 0; border-bottom: 1px solid var(--rule); vertical-align: top; }
.spec thead th { font: 400 11px/1.4 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); border-bottom: 1px solid var(--ink); }
.spec td:first-child { font-weight: 500; }
.spec .unit { font: 400 12px var(--f-mono); color: var(--graphite); white-space: nowrap; }
.table-scroll { overflow-x: auto; }

.columns-3 { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.col-list h3 { font-size: 20px; font-weight: 400; padding-bottom: 14px; border-bottom: 1px solid var(--ink); margin-bottom: 4px; }
.col-list ul { list-style: none; padding: 0; }
.col-list li { padding-block: 12px; border-bottom: 1px solid var(--rule); color: var(--graphite); font-size: 15px; }

.tags { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; padding: 0; }
.tags li { border: 1px solid var(--rule); padding: 6px 12px; font-size: 14px; color: var(--graphite); background: var(--white); }

/* ---------- Références ---------- */
.ref-empty { border-top: 1px solid var(--ink); border-bottom: 1px solid var(--rule); padding-block: clamp(48px, 8vw, 96px); display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 24px; align-items: end; }
.ref-empty .mono { grid-column: 1 / 4; }
.ref-empty p { grid-column: 4 / 12; font: 300 clamp(26px, 3.4vw, 44px)/1.15 var(--f-sans); color: var(--ink); max-width: 18em; }
.refs { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(32px, 4vw, 56px) 24px; list-style: none; padding: 0; }
.ref { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.ref img { aspect-ratio: 3 / 2; object-fit: cover; width: 100%; }
.ref h3 { font-size: clamp(22px, 2vw, 28px); font-weight: 400; }
.ref dl { display: grid; grid-template-columns: auto 1fr; gap: 6px 16px; font-size: 14px; }
.ref dt { font: 400 11px/1.9 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); }
.ref p { color: var(--graphite); font-size: 15px; }

/* ---------- Contact ---------- */
.cartouche { display: grid; grid-template-columns: 2fr 1fr 1fr; border: 1px solid var(--ink); }
.cartouche > div { padding: clamp(20px, 3vw, 36px); border-right: 1px solid var(--ink); display: flex; flex-direction: column; gap: 12px; min-width: 0; }
.cartouche > div:last-child { border-right: 0; }
.cartouche h2 { font-size: clamp(28px, 3.4vw, 44px); line-height: 1.08; }
.cartouche p { color: var(--graphite); max-width: 32em; }
.cartouche .btn { margin-top: auto; }
address { font-style: normal; color: var(--graphite); }
.big { font-size: 17px; overflow-wrap: anywhere; }

.contact-grid { align-items: start; }
.contact-form { grid-column: 1 / 8; min-width: 0; }
.contact-side { grid-column: 9 / 13; display: flex; flex-direction: column; gap: 32px; min-width: 0; }
.contact-side .block { display: flex; flex-direction: column; gap: 8px; border-top: 1px solid var(--ink); padding-top: 14px; }
.copy-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.copy-btn { background: none; border: 1px solid var(--rule); font: 400 11px var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; padding: 4px 8px; cursor: pointer; color: var(--graphite); }
.copy-btn:hover { border-color: var(--ink); color: var(--ink); }

form { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 22px 24px; }
.field { display: flex; flex-direction: column; gap: 8px; min-width: 0; }
.field.full { grid-column: 1 / -1; }
.field label { font: 400 11px/1.4 var(--f-mono); letter-spacing: 0.08em; text-transform: uppercase; color: var(--graphite); }
.field input, .field select, .field textarea {
  font: 400 16px/1.4 var(--f-sans); color: var(--ink);
  background: transparent; border: 0; border-bottom: 1px solid var(--rule);
  padding: 10px 0; border-radius: 0; width: 100%;
  -webkit-appearance: none; appearance: none;
}
.field select { background-image: linear-gradient(45deg, transparent 50%, var(--graphite) 50%), linear-gradient(135deg, var(--graphite) 50%, transparent 50%); background-position: calc(100% - 10px) 55%, calc(100% - 5px) 55%; background-size: 5px 5px; background-repeat: no-repeat; padding-right: 24px; }
.field textarea { min-height: 140px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: none; border-bottom-color: var(--ink); }
.field .req { color: var(--ink); }
.hp { position: absolute; left: -9999px; }
.form-foot { grid-column: 1 / -1; display: flex; flex-direction: column; gap: 16px; }
.form-foot small { color: var(--graphite); font-size: 13px; max-width: 40em; }
.form-status { font-size: 15px; padding: 14px 16px; border-left: 2px solid var(--ink); background: var(--white); }
.form-status.error { border-left-color: #8a2b20; }

/* ---------- Texte courant (mentions) ---------- */
.prose { max-width: 44em; display: flex; flex-direction: column; gap: 18px; color: var(--graphite); }
.prose h2 { font-size: 24px; color: var(--ink); margin-top: 24px; }
.prose a { text-underline-offset: 3px; }

/* ---------- Pied de page ---------- */
.foot { border-top: 1px solid var(--rule); padding-block: 40px 32px; }
.foot .grid { align-items: start; row-gap: 32px; }
.foot .brandcol { grid-column: 1 / 5; display: flex; flex-direction: column; gap: 14px; }
.foot .brandcol img { height: 10px; width: auto; align-self: flex-start; object-fit: contain; }
.foot .navcol { grid-column: 6 / 9; display: flex; flex-direction: column; gap: 8px; }
.foot .contactcol { grid-column: 9 / 13; display: flex; flex-direction: column; gap: 8px; }
.foot a { text-decoration: none; font-size: 14px; color: var(--graphite); }
.foot a:hover { color: var(--ink); }
.foot .small { font-size: 14px; color: var(--graphite); }
.foot .legal { margin-top: 32px; padding-top: 20px; border-top: 1px solid var(--rule); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 12px; }

/* ---------- Apparition douce ---------- */
@media (prefers-reduced-motion: no-preference) {
  .reveal { animation: rise 0.8s cubic-bezier(.2, .7, .2, 1) both; }
  .reveal.d1 { animation-delay: 0.08s; }
  .reveal.d2 { animation-delay: 0.16s; }
  @keyframes rise { from { opacity: 0.001; transform: translateY(14px); } to { opacity: 1; transform: none; } }
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .hero h1, .hero .lede { grid-column: 1 / -1; }
  .hero .curve { display: none; }
  .sec-head .mono, .sec-head h2, .sec-head .intro { grid-column: 1 / -1; }
  .sec-head .mono { padding-top: 0; }
  .steps > li { grid-template-columns: 40px minmax(0, 1fr); gap: 8px 16px; }
  .steps .n { grid-column: 1; }
  .steps h3, .steps .body { grid-column: 2; }
  .note p { grid-column: 1 / -1; }
  .types .photo, .types .col { grid-column: 1 / -1; }
  .types .photo img { aspect-ratio: 4 / 3; }
  .show-text, .show-photos { grid-column: 1 / -1; }
  .partner { flex-basis: 33.333%; }
  .cartouche { grid-template-columns: 1fr; }
  .cartouche > div { border-right: 0; border-bottom: 1px solid var(--ink); }
  .cartouche > div:last-child { border-bottom: 0; }
  .contact-form, .contact-side { grid-column: 1 / -1; }
  .columns-3 { grid-template-columns: 1fr; gap: 40px; }
  .ref-empty .mono, .ref-empty p { grid-column: 1 / -1; }
  .foot .brandcol, .foot .navcol, .foot .contactcol { grid-column: 1 / -1; }
}
@media (max-width: 720px) {
  .menu-btn { display: block; }
  .nav { display: none; position: absolute; top: var(--header-h); left: 0; right: 0; flex-direction: column; gap: 0; background: var(--paper); border-bottom: 1px solid var(--rule); padding: 8px var(--gutter) 20px; }
  .nav.open { display: flex; }
  .nav a { padding-block: 13px; font-size: 17px; color: var(--ink); border-bottom: 1px solid var(--rule); }
  .nav a[aria-current="page"] { text-decoration: none; font-weight: 500; }
  .nav .cta { border-bottom: 1px solid var(--rule); padding-bottom: 13px; }
  .ratio-wide img { aspect-ratio: 4 / 3; }
  .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .partner { flex-basis: 50%; }
  form { grid-template-columns: 1fr; }
  .refs { grid-template-columns: 1fr; }
  .show-photos { grid-template-columns: 1fr 1fr; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
