/* =========================================================
   MELIMADERA — Site public
   Palette : plâtre / encre / bleu Melimadera / bronze Monaji
   Typo : Jost (latin), Noto Kufi Arabic (arabe)
   ========================================================= */
:root {
  --plaster: #F1F2EF;
  --paper: #FFFFFF;
  --ink: #15212C;
  --ink-2: #34414C;
  --stone: #5C6570;
  --rule: #D8DBD7;
  --mist: #E5E7E3;
  --blue: #0B6CB0;
  --blue-deep: #08518A;
  --blue-wash: #E3EDF6;
  --bronze: #A26D2C;
  --ok: #1D6B46; --ok-bg: #E5F1E9;
  --err: #A3261C; --err-bg: #F7E6E3;
  --font: "Jost", ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --display: "Newsreader", "Iowan Old Style", Georgia, "Times New Roman", serif;
  --fs-s: .875rem;
  --fs-0: 1.0625rem;
  --fs-1: 1.25rem;
  --fs-2: 1.5rem;
  --fs-3: clamp(1.75rem, 2.4vw, 2.25rem);
  --fs-4: clamp(2.1rem, 3.6vw, 3.25rem);
  --fs-5: clamp(2.7rem, 6.6vw, 5.75rem);
  --wrap: 1320px;
  --gut: clamp(20px, 4vw, 56px);
  --sec: clamp(64px, 8vw, 120px);
  --r: 2px;
  --ease: cubic-bezier(.2, .7, .2, 1);
  --hdr-h: 76px;
}
:root[lang="ar"] { --font: "Noto Kufi Arabic", "Jost", system-ui, sans-serif; --display: var(--font); }

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; scroll-padding-top: calc(var(--hdr-h) + 12px); }
body { margin: 0; background: var(--plaster); color: var(--ink); font: 400 var(--fs-0)/1.65 var(--font); -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility; overflow-x: hidden; }
img, svg, video, iframe { display: block; max-width: 100%; }
img { height: auto; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; font-family: var(--display); font-weight: 400; line-height: 1.12; text-wrap: balance; }
p { margin: 0 0 1em; }
[hidden] { display: none !important; }
:lang(ar) h1, :lang(ar) h2, :lang(ar) h3 { letter-spacing: 0 !important; line-height: 1.35; }

.wrap { width: 100%; max-width: var(--wrap); margin-inline: auto; padding-inline: var(--gut); }
.sr-only, .hp { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0; }
.hp { inset-inline-start: 0; top: 0; }
.skip { position: absolute; inset-inline-start: 12px; top: -60px; z-index: 100; background: var(--ink); color: #fff; padding: 10px 16px; text-decoration: none; }
.skip:focus { top: 12px; }
main:focus { outline: none; }
:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }

.ic { width: 1.15em; height: 1.15em; flex: none; }
[dir="rtl"] .flip-rtl, [dir="rtl"] .pd__nav .ic, [dir="rtl"] .viewer__nav .ic, [dir="rtl"] .crumbs .ic { transform: scaleX(-1); }

/* ---------- Typographie ---------- */
.h-section { font-size: var(--fs-4); font-weight: 400; letter-spacing: -.012em; line-height: 1.05; margin-bottom: .5em; }
.h-small { font-family: var(--font); font-size: 1rem; font-weight: 500; letter-spacing: .01em; margin: 40px 0 6px; }
.lead { color: var(--stone); max-width: 54ch; }
.link { color: var(--blue); text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .25em; display: inline-flex; align-items: center; gap: .45em; }
.link:hover { color: var(--blue-deep); text-decoration-thickness: 2px; }
.link--light { color: #fff; text-decoration-color: rgba(255,255,255,.55); }
.link--light:hover { color: #fff; text-decoration-color: #fff; }
.linklike { background: none; border: 0; padding: 0; cursor: pointer; text-align: start; }
.empty { padding: 40px; border: 1px dashed var(--rule); color: var(--stone); background: var(--paper); }

/* ---------- Boutons ---------- */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: .55em; min-height: 48px; padding: .65em 1.35em; border: 1px solid transparent; border-radius: var(--r); font-weight: 500; font-size: 1rem; line-height: 1.2; letter-spacing: .01em; text-decoration: none; cursor: pointer; transition: background-color .2s, color .2s, border-color .2s; text-align: center; }
.btn--primary { background: var(--blue); color: #fff; }
.btn--primary:hover { background: var(--blue-deep); }
.btn--ghost { border-color: var(--ink); color: var(--ink); background: transparent; }
.btn--ghost:hover { background: var(--ink); color: #fff; }
.btn--outline-light { border-color: rgba(255,255,255,.75); color: #fff; }
.btn--outline-light:hover { background: #fff; color: var(--ink); }
.btn--light { background: #fff; color: var(--ink); }
.btn--light:hover { background: var(--blue-wash); }
.btn--lg { min-height: 56px; padding-inline: 1.75em; font-size: var(--fs-0); }
.btn--sm { min-height: 40px; padding: .45em 1em; font-size: .9375rem; }
.btn--block { width: 100%; }
.btn[disabled] { opacity: .65; cursor: progress; }

/* ---------- Bandeau supérieur ---------- */
.topbar { background: var(--ink); color: rgba(255,255,255,.78); font-size: var(--fs-s); }
.topbar__in { display: flex; align-items: center; gap: 24px; min-height: 40px; }
.topbar__promo { margin: 0; color: #fff; font-weight: 400; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; }
.topbar__phones { display: flex; gap: 20px; list-style: none; margin: 0; padding: 0; }
.topbar__phones a { display: inline-flex; align-items: center; gap: 6px; text-decoration: none; }
.topbar__phones a:hover { color: #fff; }
.topbar__phones .ic { width: 14px; height: 14px; }
.lang { display: flex; gap: 2px; margin-inline-start: auto; }
.lang a { text-decoration: none; padding: 4px 8px; border-radius: var(--r); }
.lang a:hover { color: #fff; }
.lang a[aria-current] { color: #fff; background: rgba(255,255,255,.12); }

/* ---------- En-tête ---------- */
.site-header { position: sticky; top: 0; z-index: 40; background: var(--paper); border-bottom: 1px solid var(--rule); transition: background-color .3s, border-color .3s, color .3s; }
.site-header__in { display: flex; align-items: center; gap: 24px; height: var(--hdr-h); }
.brand { display: block; flex: none; }
.brand__logo { height: 58px; width: auto; }
.brand__logo--light { display: none; }
.brand--custom .brand__logo--light { background: #fff; padding: 4px 8px; border-radius: var(--r); }
.mainnav { margin-inline: auto; }
.mainnav ul { display: flex; gap: 4px; list-style: none; margin: 0; padding: 0; }
.mainnav a { display: block; padding: 8px 14px; text-decoration: none; font-weight: 500; font-size: .9688rem; position: relative; }
.mainnav a::after { content: ""; position: absolute; inset-inline: 14px; bottom: 2px; height: 1px; background: currentColor; transform: scaleX(0); transform-origin: left; transition: transform .25s var(--ease); }
.mainnav a:hover::after, .mainnav a[aria-current]::after { transform: scaleX(1); }
.site-header__actions { display: flex; align-items: center; gap: 12px; margin-inline-start: auto; }
.mainnav + .site-header__actions { margin-inline-start: 0; }
.hdr-link { display: inline-flex; align-items: center; gap: 8px; background: none; border: 0; padding: 8px 6px; cursor: pointer; font-weight: 500; font-size: .9688rem; }
.hdr-link:hover { color: var(--blue); }
.menu-toggle { display: none; width: 44px; height: 44px; align-items: center; justify-content: center; background: none; border: 0; cursor: pointer; }
.menu-toggle .ic { width: 26px; height: 26px; }
.menu-toggle .ic-close, .menu-toggle[aria-expanded="true"] .ic-open { display: none; }
.menu-toggle[aria-expanded="true"] .ic-close { display: block; }

/* En-tête transparent au-dessus de la photo d'accueil */
.site-header--overlay:not(.is-solid):not(.menu-open) { background: transparent; border-color: transparent; color: #fff; }
.site-header--overlay:not(.is-solid):not(.menu-open) .brand__logo--dark { display: none; }
.site-header--overlay:not(.is-solid):not(.menu-open) .brand__logo--light { display: block; }
.site-header--overlay:not(.is-solid):not(.menu-open) .hdr-link:hover { color: #fff; opacity: .8; }

.mobile-menu { border-top: 1px solid var(--rule); background: var(--paper); color: var(--ink); padding: 8px var(--gut) 24px; max-height: calc(100svh - var(--hdr-h)); overflow-y: auto; }
.mobile-menu ul { list-style: none; margin: 0; padding: 0; }
.mobile-menu li a { display: block; padding: 14px 0; border-bottom: 1px solid var(--rule); font-family: var(--display); font-size: var(--fs-2); font-weight: 400; text-decoration: none; }
.mobile-menu__foot { display: grid; gap: 10px; margin-top: 24px; }

@media (max-width: 1040px) {
  .mainnav, .hdr-link { display: none; }
  .menu-toggle { display: inline-flex; }
  .mainnav + .site-header__actions { margin-inline-start: auto; }
}
@media (max-width: 760px) {
  :root { --hdr-h: 64px; }
  .brand__logo { height: 46px; }
  .topbar__phones { display: none; }
  .topbar__promo { white-space: normal; font-size: .8125rem; line-height: 1.35; padding-block: 7px; }
  .hdr-cta { display: none; }
}

/* ---------- Accueil ---------- */
.hero { position: relative; color: #fff; min-height: min(calc(100svh - 40px), 940px); display: flex; align-items: flex-end; margin-top: calc(var(--hdr-h) * -1); overflow: hidden; background: var(--ink); }
.hero__media { position: absolute; inset: 0; }
.hero__img { width: 100%; height: 100%; object-fit: cover; animation: heroSettle 2.2s var(--ease) both; }
.hero__media::after { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, rgba(9,17,25,.58) 0%, rgba(9,17,25,.06) 26%, rgba(9,17,25,.14) 50%, rgba(9,17,25,.84) 100%), linear-gradient(90deg, rgba(9,17,25,.5) 0%, rgba(9,17,25,0) 62%); }
[dir="rtl"] .hero__media::after { background: linear-gradient(180deg, rgba(9,17,25,.58) 0%, rgba(9,17,25,.06) 26%, rgba(9,17,25,.14) 50%, rgba(9,17,25,.84) 100%), linear-gradient(270deg, rgba(9,17,25,.5) 0%, rgba(9,17,25,0) 62%); }
.hero__in { position: relative; display: flex; align-items: flex-end; justify-content: space-between; gap: 40px; padding-top: calc(var(--hdr-h) + 64px); padding-bottom: clamp(40px, 7vw, 96px); }
.hero__title { font-size: clamp(2.9rem, 6.8vw, 6.4rem); font-weight: 400; line-height: .98; letter-spacing: -.02em; max-width: 12ch; margin-bottom: .3em; }
.hero__lead { font-size: var(--fs-1); font-weight: 300; max-width: 40ch; color: rgba(255,255,255,.88); margin-bottom: 32px; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 12px; }
.hero__actions .link--light { align-self: center; min-height: 56px; padding-inline: 4px; font-size: 1.0625rem; font-weight: 500; }
.hero__text > * { animation: rise .9s var(--ease) both; }
.hero__text > :nth-child(2) { animation-delay: .12s; }
.hero__text > :nth-child(3) { animation-delay: .24s; }
.hero__caption { flex: none; max-width: 260px; padding-inline-start: 14px; border-inline-start: 1px solid rgba(255,255,255,.55); text-decoration: none; font-size: .9375rem; line-height: 1.4; }
.hero__caption-title { display: block; font-weight: 500; }
.hero__caption-cat { display: block; color: rgba(255,255,255,.72); }
.hero__caption:hover .hero__caption-title { text-decoration: underline; text-underline-offset: .2em; }
.hero--plain { min-height: 70svh; }
@keyframes heroSettle { from { transform: scale(1.07); } to { transform: scale(1); } }
@keyframes rise { from { opacity: 0; transform: translateY(18px); } to { opacity: 1; transform: none; } }
@media (max-width: 760px) {
  .hero { min-height: 86svh; }
  .hero__caption { display: none; }
  .hero__actions .btn { flex: 1 1 100%; }
}

/* ---------- Réalisations : index des pièces + grille ---------- */
.work { padding-block: var(--sec); }
.work__grid { display: grid; gap: 40px; grid-template-columns: minmax(0, 1fr); }
.work__grid > *, .about__grid > *, .contact__grid > *, .catband__in > *, .project__layout > *, .footer__grid > * { min-width: 0; }
.rooms { display: flex; flex-direction: column; margin-top: 36px; border-top: 1px solid var(--rule); }
.room { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; width: 100%; padding: 13px 0; background: none; border: 0; border-bottom: 1px solid var(--rule); color: var(--stone); font-family: var(--display); font-size: clamp(1.35rem, 2vw, 1.7rem); font-weight: 400; line-height: 1.2; text-align: start; cursor: pointer; position: relative; transition: color .2s, padding .3s var(--ease); }
.room:hover { color: var(--ink); }
.room[aria-pressed="true"] { color: var(--ink); padding-inline-start: 20px; }
.room[aria-pressed="true"]::before { content: ""; position: absolute; inset-inline-start: 0; top: calc(13px + .6em - 4px); width: 8px; height: 8px; border-radius: 50%; background: var(--bronze); }
.room__n { font-family: var(--font); font-size: .875rem; font-weight: 400; color: var(--stone); font-variant-numeric: tabular-nums; }
@media (min-width: 1040px) {
  .work__grid { grid-template-columns: minmax(250px, 310px) minmax(0, 1fr); gap: 72px; }
  .work__side { position: sticky; top: calc(var(--hdr-h) + 32px); align-self: start; }
}
@media (max-width: 1039px) {
  .rooms { position: relative; flex-direction: row; overflow-x: auto; border-top: 0; border-bottom: 1px solid var(--rule); scrollbar-width: none; margin-inline: calc(var(--gut) * -1); padding-inline: var(--gut); gap: 4px; }
  .rooms::-webkit-scrollbar { display: none; }
  .room { flex: none; width: auto; font-size: 1.125rem; font-weight: 400; padding: 12px 12px; border-bottom: 2px solid transparent; margin-bottom: -1px; }
  .room[aria-pressed="true"] { padding-inline-start: 12px; border-bottom-color: var(--ink); }
  .room[aria-pressed="true"]::before { display: none; }
}

.pgrid { list-style: none; margin: 0; padding: 0; display: grid; gap: clamp(28px, 3vw, 40px) clamp(16px, 2vw, 28px); grid-template-columns: 1fr; }
@media (min-width: 640px) { .pgrid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1240px) { .pgrid { grid-template-columns: repeat(3, 1fr); } }
.pgrid--3 { margin-top: 32px; }
/* Première réalisation mise en avant : pleine largeur (2 colonnes sur bureau) */
.pgrid > .pcard:first-child { grid-column: 1 / -1; }
.pgrid > .pcard:first-child .pcard__fig { aspect-ratio: 4 / 3; }
@media (min-width: 1240px) {
  .pgrid > .pcard:first-child { grid-column: span 2; }
  .pgrid > .pcard:first-child .pcard__fig { aspect-ratio: 16 / 10; }
}
.pcard__link { display: block; text-decoration: none; }
.pcard__fig { display: block; position: relative; aspect-ratio: 4 / 5; overflow: hidden; background: var(--mist); }
.pcard__fig img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.pcard__link:hover .pcard__fig img { transform: scale(1.02); }
.pcard__title { display: block; margin-top: 16px; font-family: var(--display); font-size: clamp(1.3rem, 1.8vw, 1.6rem); line-height: 1.2; }
.pcard__meta { display: block; margin-top: 2px; color: var(--stone); font-size: .9375rem; }
.pcard__link:hover .pcard__title { text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.pcard__count { position: absolute; inset-block-end: 12px; inset-inline-end: 12px; display: inline-flex; align-items: center; gap: 6px; padding: 4px 9px; background: rgba(21,33,44,.74); color: #fff; font-size: .8125rem; border-radius: var(--r); }
.pcard__count .ic { width: 15px; height: 15px; }
.pcard.is-in { animation: fadeIn .45s var(--ease) both; }
@keyframes fadeIn { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }
.work__more { margin-top: 48px; }

/* ---------- Savoir-faire ---------- */
.about { background: var(--paper); padding-block: var(--sec); }
.about__grid { display: grid; gap: 48px; align-items: center; }
.about__text > p { font-size: var(--fs-1); font-weight: 300; line-height: 1.6; color: var(--ink-2); max-width: 46ch; }
.services { list-style: none; padding: 0; margin: 12px 0 0; display: grid; grid-template-columns: 1fr; column-gap: 32px; }
.services li { padding: 11px 0; border-bottom: 1px solid var(--rule); }
.about__fig { margin: 0; }
.about__fig img { width: 100%; aspect-ratio: 4 / 5; object-fit: cover; }
@media (min-width: 600px) { .services { grid-template-columns: 1fr 1fr; } }
@media (min-width: 960px) { .about__grid { grid-template-columns: 1.05fr .95fr; gap: 88px; } }

/* ---------- Méthode ---------- */
.process { padding-block: var(--sec); }
.steps { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: 1fr; column-gap: 32px; }
.step { border-top: 1px solid var(--ink); padding: 24px 0 36px; }
.step__n { display: block; font-family: var(--display); font-size: clamp(3rem, 5vw, 4.5rem); font-weight: 400; line-height: 1; color: var(--bronze); margin-bottom: 20px; }
.step__t { font-size: var(--fs-2); margin-bottom: 8px; }
.step p { color: var(--stone); margin: 0; max-width: 30ch; }
.process__offer { margin: 24px 0 0; font-size: var(--fs-1); font-weight: 300; display: flex; flex-wrap: wrap; gap: 8px 20px; align-items: baseline; }
@media (min-width: 700px) { .steps { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .steps { grid-template-columns: repeat(4, 1fr); } }

/* ---------- Avant / après ---------- */
.ba { background: var(--paper); padding-block: var(--sec); }
.ba__list { display: grid; gap: 40px; margin-top: 32px; }
.ba-slider { position: relative; aspect-ratio: 16 / 9; overflow: hidden; background: var(--mist); user-select: none; touch-action: pan-y; }
.ba-slider__img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.ba-slider__before { position: absolute; inset: 0; clip-path: inset(0 calc(100% - var(--pos)) 0 0); }
[dir="rtl"] .ba-slider__before { clip-path: inset(0 0 0 calc(100% - var(--pos))); }
.ba-slider__line { position: absolute; top: 0; bottom: 0; inset-inline-start: var(--pos); width: 2px; margin-inline-start: -1px; background: #fff; pointer-events: none; }
.ba-slider__knob { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 52px; height: 52px; border-radius: 50%; background: #fff; color: var(--ink); display: flex; align-items: center; justify-content: center; box-shadow: 0 2px 12px rgba(0,0,0,.25); }
.ba-slider__knob .ic { width: 16px; height: 16px; }
.ba-slider__range { position: absolute; inset: 0; width: 100%; height: 100%; margin: 0; opacity: 0; cursor: ew-resize; }
.ba-slider:has(.ba-slider__range:focus-visible) { outline: 2px solid var(--blue); outline-offset: 4px; }
.ba-tag { position: absolute; bottom: 16px; padding: 4px 10px; background: rgba(21,33,44,.78); color: #fff; font-size: var(--fs-s); pointer-events: none; }
.ba-tag--before { inset-inline-start: 16px; }
.ba-tag--after { inset-inline-end: 16px; }
@media (max-width: 700px) { .ba-slider { aspect-ratio: 4 / 3; } }

/* ---------- Conception 3D (aperçu) ---------- */
.d3teaser { padding-block: var(--sec); }
.sec-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: 16px 40px; }
.sec-head .lead { margin: 0; }
.d3row { list-style: none; padding: 0; margin: 40px 0 0; display: grid; grid-template-columns: repeat(2, 1fr); gap: 24px 16px; }
.d3row__item { display: block; text-decoration: none; }
.d3row__fig { display: block; aspect-ratio: 4 / 3; overflow: hidden; background: var(--mist); }
.d3row__fig img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.d3row__item:hover img { transform: scale(1.035); }
.d3row__t { display: block; margin-top: 10px; }
@media (min-width: 900px) { .d3row { grid-template-columns: repeat(4, 1fr); gap: 24px; } }

/* ---------- Vidéo ---------- */
.video { background: var(--ink); color: #fff; padding-block: var(--sec); }
.video__frame { position: relative; aspect-ratio: 16 / 9; background: #000; margin-top: 32px; }
.video__frame iframe, .video__frame video { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; object-fit: cover; }

/* ---------- Avis ---------- */
.reviews { background: var(--paper); padding-block: var(--sec); }
.quotes { list-style: none; padding: 0; margin: 40px 0 0; display: grid; gap: 40px 48px; grid-template-columns: 1fr; }
.quote blockquote { margin: 0; }
.quote blockquote p { font-size: var(--fs-1); font-weight: 300; line-height: 1.55; }
.quote__by { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; margin: 0; padding-top: 14px; border-top: 1px solid var(--rule); }
.quote__name { font-weight: 500; }
.stars { display: inline-flex; gap: 2px; }
.stars .ic { width: 16px; height: 16px; color: var(--rule); }
.stars .ic.on { color: var(--bronze); fill: currentColor; }
@media (min-width: 760px) { .quotes { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .quotes { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Magazine ---------- */
.journal { padding-block: var(--sec); }
.articles { display: grid; gap: 40px 28px; margin-top: 40px; grid-template-columns: 1fr; }
.article__fig { aspect-ratio: 3 / 2; overflow: hidden; background: var(--mist); margin-bottom: 16px; }
.article__fig img { width: 100%; height: 100%; object-fit: cover; }
.article__cat { color: var(--bronze); font-size: var(--fs-s); margin: 0 0 6px; }
.article__t { font-size: var(--fs-2); font-weight: 400; margin-bottom: 10px; }
.article p { color: var(--ink-2); }
.article__more summary { cursor: pointer; color: var(--blue); list-style: none; }
.article__more summary::-webkit-details-marker { display: none; }
.article__more[open] summary { margin-bottom: 8px; }
@media (min-width: 760px) { .articles { grid-template-columns: repeat(3, 1fr); } }

/* ---------- Bandeau catalogue ---------- */
.catband { background: var(--ink); color: rgba(255,255,255,.82); padding-block: clamp(56px, 7vw, 96px); }
.catband .h-section { color: #fff; font-size: var(--fs-3); }
.catband__in { display: grid; gap: 32px; align-items: center; }
.catband__text p { max-width: 50ch; margin: 0; }
.catform { display: grid; gap: 12px; }
.catform--band { grid-template-columns: 1fr; }
.catform--band .field > span { color: rgba(255,255,255,.8); }
.catform--band input { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.28); color: #fff; }
.catform--band input:focus { border-color: #fff; box-shadow: none; background: rgba(255,255,255,.1); }
.catform .field { margin: 0; }
@media (min-width: 760px) { .catform--band { grid-template-columns: repeat(3, 1fr); align-items: end; } .catform--band .btn { grid-column: 1 / -1; justify-self: start; } }
@media (min-width: 1100px) { .catband__in { grid-template-columns: .9fr 1.1fr; gap: 64px; } }

/* ---------- Contact & devis ---------- */
.contact { background: var(--paper); padding-block: var(--sec); }
.contact__grid { display: grid; gap: 48px; }
.showroom { border-top: 1px solid var(--rule); padding: 20px 0 6px; }
.showroom__t { font-size: var(--fs-1); margin-bottom: 6px; }
.showroom p { margin: 0 0 4px; color: var(--ink-2); }
.showroom__links { display: flex; flex-wrap: wrap; gap: 6px 20px; margin-top: 10px !important; }
.showroom__links a { display: inline-flex; align-items: center; gap: 6px; color: var(--blue); text-decoration: none; font-weight: 500; padding: 6px 0; }
.showroom__links a:hover { text-decoration: underline; text-underline-offset: .2em; }
.contact__hours { display: flex; align-items: center; gap: 8px; color: var(--stone); border-top: 1px solid var(--rule); padding-top: 18px; margin-top: 14px; }
@media (min-width: 1040px) { .contact__grid { grid-template-columns: 5fr 7fr; gap: 80px; align-items: start; } .contact__info { position: sticky; top: calc(var(--hdr-h) + 32px); } }

.devis { background: var(--plaster); padding: clamp(22px, 4vw, 48px); }
.devis__row { display: grid; gap: 0 16px; }
@media (min-width: 640px) { .devis__row { grid-template-columns: 1fr 1fr; } }
.field { display: block; margin: 0 0 20px; }
.field > span, .field > legend, .field--file > span { display: block; margin-bottom: 8px; font-size: .9375rem; font-weight: 500; color: inherit; }
input[type="text"], input[type="tel"], input[type="email"], input[type="url"], select, textarea {
  width: 100%; min-height: 50px; padding: 12px 14px; background: #fff; border: 1px solid #C4C9C5; border-radius: var(--r); font-size: 1rem; color: var(--ink); transition: border-color .2s, box-shadow .2s;
}
textarea { min-height: 130px; resize: vertical; line-height: 1.5; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--blue); box-shadow: 0 0 0 3px var(--blue-wash); }
select { appearance: none; -webkit-appearance: none; padding-inline-end: 44px; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2315212C' stroke-width='1.6' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-size: 18px; background-position: right 14px center; }
[dir="rtl"] select { background-position: left 14px center; }
::placeholder { color: #8A929A; }
.field--choices { border: 0; padding: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.field--choices legend { width: 100%; float: left; }
[dir="rtl"] .field--choices legend { float: right; }
.choice { position: relative; }
.choice input { position: absolute; opacity: 0; inset: 0; margin: 0; cursor: pointer; }
.choice span { display: inline-flex; align-items: center; min-height: 44px; padding: 8px 16px; background: #fff; border: 1px solid #C4C9C5; border-radius: var(--r); cursor: pointer; transition: border-color .2s, background-color .2s; }
.choice input:checked + span { border-color: var(--blue); background: var(--blue-wash); color: var(--blue-deep); }
.choice input:focus-visible + span { outline: 2px solid var(--blue); outline-offset: 2px; }
.field--file small { display: block; color: var(--stone); font-size: var(--fs-s); margin-top: 6px; }
.filepick { position: relative; display: flex; flex-wrap: wrap; align-items: center; gap: 10px 14px; }
.filepick input { position: absolute; inset: 0; opacity: 0; cursor: pointer; width: 100%; }
.filepick__btn { display: inline-flex; align-items: center; gap: 8px; min-height: 44px; padding: 8px 16px; border: 1px solid var(--ink); border-radius: var(--r); background: #fff; font-weight: 500; }
.filepick:hover .filepick__btn { background: var(--ink); color: #fff; }
.filepick input:focus-visible ~ .filepick__btn { outline: 2px solid var(--blue); outline-offset: 2px; }
.filepick__name { color: var(--stone); font-size: .9375rem; word-break: break-all; }
.filepick__name.is-set { color: var(--ink); }
.refchip { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 8px 10px 14px; margin: 0 0 20px; background: var(--blue-wash); color: var(--blue-deep); }
.refchip button { background: none; border: 0; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; cursor: pointer; color: inherit; }
.devis__note { display: flex; align-items: flex-start; gap: 8px; margin: 16px 0 0; color: var(--stone); font-size: var(--fs-s); }
.devis__note .ic { margin-top: 2px; }

.notice { display: flex; align-items: flex-start; gap: 10px; padding: 14px 16px; margin: 0 0 20px; border-inline-start: 3px solid currentColor; }
.notice p { margin: 0; }
.notice .ic { margin-top: 3px; }
.notice--ok { background: var(--ok-bg); color: var(--ok); }
.notice--err { background: var(--err-bg); color: var(--err); }
.catband .notice { margin-top: 20px; }

/* ---------- Partenaires ---------- */
.partners { padding-block: clamp(56px, 7vw, 88px); }
.partners .h-small { margin: 0 0 28px; color: var(--stone); font-weight: 400; }
.logos { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; align-items: center; gap: 32px 56px; }
.logos img { height: 46px; width: auto; max-width: 150px; object-fit: contain; filter: grayscale(1); opacity: .72; transition: filter .3s, opacity .3s; }
.logos li:hover img { filter: none; opacity: 1; }

/* ---------- Pied de page ---------- */
.site-footer { background: var(--ink); color: rgba(255,255,255,.72); padding-top: clamp(56px, 7vw, 88px); font-size: .9688rem; }
.site-footer a { color: #fff; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; text-underline-offset: .2em; }
.footer__grid { display: grid; gap: 40px; grid-template-columns: 1fr; }
.footer__h { color: #fff; font-size: 1rem; font-weight: 500; margin-bottom: 16px; }
.footer__logo { height: 58px; width: auto; margin-bottom: 18px; }
.footer__logo--plate { background: #fff; padding: 6px 10px; border-radius: var(--r); }
.footer__logo2 { height: 64px; width: auto; margin-bottom: 18px; }
.footer__brand p { max-width: 34ch; }
.footer__sr { margin-bottom: 16px; }
.footer__sr p { margin: 0; }
.footer__srname { color: #fff; }
.footer__hours { display: flex; gap: 8px; align-items: center; }
.footer__links, .footer__social { list-style: none; padding: 0; margin: 0; }
.footer__links li { margin-bottom: 8px; }
.footer__links .linklike { color: #fff; }
.footer__links .linklike:hover { text-decoration: underline; }
.footer__social { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 16px; }
.footer__social a { display: flex; align-items: center; justify-content: center; width: 44px; height: 44px; border: 1px solid rgba(255,255,255,.22); border-radius: 50%; }
.footer__social a:hover { background: #fff; color: var(--ink); text-decoration: none; }
.footer__legal { margin-top: 56px; padding-block: 22px; border-top: 1px solid rgba(255,255,255,.12); font-size: var(--fs-s); }
.footer__legal p { margin: 0; }
@media (min-width: 700px) { .footer__grid { grid-template-columns: 1fr 1fr; } }
@media (min-width: 1100px) { .footer__grid { grid-template-columns: 1.6fr 1.2fr .9fr .9fr; gap: 48px; } }

.wa-float { position: fixed; inset-block-end: 20px; inset-inline-end: 20px; z-index: 30; width: 54px; height: 54px; border-radius: 50%; background: #1FA855; color: #fff; display: flex; align-items: center; justify-content: center; box-shadow: 0 6px 18px rgba(0,0,0,.22); transition: transform .2s, background-color .2s; }
.wa-float:hover { background: #178A45; transform: translateY(-2px); }
.wa-float .ic { width: 28px; height: 28px; stroke-width: 1.7; }

/* ---------- Fenêtres (dialog) ---------- */
.dlg { border: 0; padding: 0; background: transparent; color: var(--ink); max-width: none; max-height: none; }
.dlg::backdrop { background: rgba(10,18,26,.72); }
.dlg[open] { animation: dlgIn .28s var(--ease); }
@keyframes dlgIn { from { opacity: 0; transform: translateY(10px); } to { opacity: 1; transform: none; } }
.dlg__box { position: relative; background: var(--paper); padding: clamp(28px, 4vw, 44px); }
.dlg--catalog { width: min(100% - 32px, 480px); }
.dlg__title { font-size: var(--fs-3); font-weight: 300; margin-bottom: 10px; padding-inline-end: 40px; }
.dlg__text { color: var(--stone); }
.dlg__close { position: absolute; top: 10px; inset-inline-end: 10px; z-index: 3; width: 44px; height: 44px; display: flex; align-items: center; justify-content: center; background: transparent; border: 0; cursor: pointer; color: var(--ink); }
.dlg__close .ic { width: 24px; height: 24px; }
.dlg__close--light { color: #fff; position: fixed; top: 14px; inset-inline-end: 14px; }
html.dlg-lock { overflow: hidden; }

/* Fiche projet (modale) */
.dlg--project { width: min(100% - 24px, 1320px); height: min(100% - 24px, 880px); }
.pd { display: grid; grid-template-rows: minmax(0, 1fr); height: 100%; background: var(--paper); position: relative; }
.pd__media { background: #0E161E; display: flex; flex-direction: column; min-height: 0; }
.pd__stage { position: relative; flex: 1; min-height: 0; }
.pd__stage img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: contain; }
.pd__nav, .viewer__nav { position: absolute; top: 50%; transform: translateY(-50%); width: 48px; height: 48px; border: 0; border-radius: 50%; background: rgba(255,255,255,.92); color: var(--ink); display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 2; }
.pd__nav:hover, .viewer__nav:hover { background: #fff; }
.pd__nav--prev, .viewer__nav--prev { inset-inline-start: 14px; }
.pd__nav--next, .viewer__nav--next { inset-inline-end: 14px; }
.pd__counter { position: absolute; bottom: 10px; inset-inline-start: 16px; margin: 0; color: rgba(255,255,255,.85); font-size: var(--fs-s); }
.pd__thumbs { display: flex; gap: 8px; padding: 10px; overflow-x: auto; flex: none; }
.pd__thumbs button { flex: none; width: 72px; height: 54px; padding: 0; border: 2px solid transparent; background: #000; cursor: pointer; opacity: .65; }
.pd__thumbs button[aria-current="true"] { border-color: #fff; opacity: 1; }
.pd__thumbs img { width: 100%; height: 100%; object-fit: cover; }
.pd__info { padding: clamp(24px, 3vw, 40px); overflow-y: auto; }
.pd__cat { color: var(--stone); margin: 0 0 6px; padding-inline-end: 40px; }
.pd__title { font-size: var(--fs-3); font-weight: 300; margin-bottom: 20px; }
.pd__desc { color: var(--ink-2); margin-top: 20px; white-space: pre-line; }
.pd__actions { display: grid; gap: 10px; margin-top: 28px; }
.pd__actions .link { justify-self: start; margin-top: 6px; }
.specs, .pd__specs { margin: 0; }
.specs > div, .pd__specs > div { display: flex; justify-content: space-between; gap: 16px; padding: 10px 0; border-bottom: 1px solid var(--rule); }
.specs dt, .pd__specs dt { color: var(--stone); }
.specs dd, .pd__specs dd { margin: 0; text-align: end; }
@media (min-width: 1000px) {
  .pd { grid-template-columns: minmax(0, 1fr) 380px; }
  .pd__media .pd__stage { min-height: 0; }
}
@media (max-width: 999px) {
  .dlg--project { width: 100%; height: 100%; max-height: 100%; margin: 0; }
  .pd { grid-template-rows: 58% minmax(0, 1fr); }
  .pd__info .dlg__close { position: absolute; }
  .pd > .dlg__close { color: #fff; background: rgba(0,0,0,.35); border-radius: 50%; }
}

/* Visionneuse plein écran */
.dlg--viewer { width: 100%; height: 100%; max-width: 100%; max-height: 100%; margin: 0; background: rgba(9,15,21,.97); }
.dlg--viewer::backdrop { background: transparent; }
.viewer { margin: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; padding: 64px 16px 20px; }
.viewer img { max-width: 100%; max-height: calc(100% - 36px); object-fit: contain; }
.viewer__cap { color: rgba(255,255,255,.75); font-size: var(--fs-s); }
.viewer__nav { position: fixed; }

/* ---------- Page projet ---------- */
.project { padding-block: 32px var(--sec); }
.crumbs { margin-bottom: 24px; }
.crumbs a { display: inline-flex; align-items: center; gap: 8px; color: var(--stone); text-decoration: none; }
.crumbs a:hover { color: var(--ink); }
.project__cat { color: var(--stone); margin: 0 0 4px; }
.project__title { font-size: var(--fs-4); font-weight: 300; letter-spacing: -.02em; line-height: 1.08; margin-bottom: 32px; }
.project__layout { display: grid; gap: 40px; }
.project__gallery { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.project__shot { padding: 0; border: 0; background: var(--mist); cursor: zoom-in; display: block; overflow: hidden; aspect-ratio: 4 / 3; }
.project__shot--lead { grid-column: 1 / -1; aspect-ratio: 3 / 2; }
.project__shot img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.project__shot:hover img { transform: scale(1.02); }
.project__desc { margin-top: 24px; color: var(--ink-2); }
.project__actions { display: grid; gap: 10px; margin-top: 28px; }
@media (min-width: 1000px) {
  .project__layout { grid-template-columns: minmax(0, 1fr) 360px; gap: 64px; }
  .project__info { position: sticky; top: calc(var(--hdr-h) + 24px); align-self: start; }
}
.related { background: var(--paper); padding-block: var(--sec); }
.notfound { padding-block: var(--sec); }

/* ---------- Galerie 3D ---------- */
.pagehead { padding-block: clamp(48px, 6vw, 88px) 24px; }
.pagehead__title { font-size: var(--fs-4); font-weight: 300; letter-spacing: -.02em; line-height: 1.08; margin-bottom: .4em; }
.tabs { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 28px; border-bottom: 1px solid var(--rule); }
.tab { background: none; border: 0; border-bottom: 2px solid transparent; margin-bottom: -1px; padding: 10px 14px; cursor: pointer; color: var(--stone); font-weight: 500; }
.tab:hover { color: var(--ink); }
.tab[aria-pressed="true"] { color: var(--ink); border-bottom-color: var(--ink); }
.d3page { padding-block: 24px var(--sec); }
.d3grid { list-style: none; margin: 0; padding: 0; display: grid; gap: 28px; grid-template-columns: 1fr; }
@media (min-width: 640px) { .d3grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1100px) { .d3grid { grid-template-columns: repeat(3, 1fr); } }
.d3card { background: var(--paper); display: flex; flex-direction: column; }
.d3card__fig { display: block; width: 100%; padding: 0; border: 0; aspect-ratio: 4 / 3; overflow: hidden; background: var(--mist); cursor: zoom-in; }
.d3card__fig img { width: 100%; height: 100%; object-fit: cover; transition: transform .9s var(--ease); }
.d3card__fig:hover img { transform: scale(1.035); }
.d3card__body { padding: 20px 24px 26px; }
.d3card__t { font-size: var(--fs-1); margin-bottom: 4px; }
.d3card__cat { color: var(--stone); font-size: var(--fs-s); margin-bottom: 10px; }
.d3card__body > p:not(.d3card__cat):not(.d3card__actions) { color: var(--ink-2); }
.d3card__actions { display: flex; flex-wrap: wrap; gap: 8px; margin: 16px 0 0; }
.d3page__cta { margin-top: 64px; padding-top: 28px; border-top: 1px solid var(--rule); display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 16px; }
.d3page__cta p { margin: 0; font-size: var(--fs-1); font-weight: 300; }

/* ---------- Accessibilité : mouvement réduit ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

@media print {
  .topbar, .site-header, .wa-float, .catband, .devis, dialog { display: none !important; }
}
