:root {
  --ink: #161616;
  --muted: #777;
  --line: #e4e4e1;
  --paper: #fff;
  --soft: #f6f6f3;
  --gap: clamp(16px, 3vw, 32px);
  --font: "Helvetica Neue", Helvetica, Arial, system-ui, sans-serif;
  color-scheme: light;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--paper); color: var(--ink); font: 16px/1.5 var(--font); }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 3px; }
h1 { font-size: clamp(1.5rem, 3vw, 2rem); font-weight: 400; letter-spacing: -0.01em; margin: 0 0 0.6em; }
h2 { font-size: 1.1rem; font-weight: 400; }
/* Titres en cartel : petites capitales, filet noir, information à droite */
body:not(.admin) main h1, .kicker {
  display: flex; justify-content: space-between; align-items: baseline; gap: 1em;
  font-size: 0.78rem; font-weight: 400; letter-spacing: 0.14em; text-transform: uppercase; color: var(--ink);
  border-bottom: 1px solid var(--ink); padding-bottom: 6px; margin: 2.2em 0 1.4em;
}
.kicker { margin-top: 3.2em; }
body:not(.admin) main h1 .meta { color: var(--muted); letter-spacing: 0.08em; text-align: right; }
/* Sauf le nom d'une œuvre ou d'un·e artiste, qui restent en grand */
body:not(.admin) main .work-info h1, body:not(.admin) main .artist h1 {
  display: block; font-size: clamp(1.5rem, 3vw, 2rem); letter-spacing: -0.01em; text-transform: none; border: 0; padding: 0; margin: 0 0 0.4em;
}
.muted { color: var(--muted); }
.small { font-size: 0.85rem; }

.site-head, .site-foot, main { max-width: 1240px; margin: 0 auto; padding: 0 var(--gap); }
.site-head { display: flex; align-items: center; justify-content: space-between; gap: var(--gap); padding-top: 12px; padding-bottom: 12px; flex-wrap: wrap; }
.logo img { width: clamp(110px, 13vw, 160px); height: auto; }
.site-head { padding-top: clamp(16px, 3vw, 32px); }
.site-head nav, .site-foot nav { display: flex; gap: 1.2em; flex-wrap: wrap; text-transform: lowercase; }
.site-head nav a, .site-foot nav a { text-decoration: none; }
.site-head nav a:hover, .site-foot nav a:hover { text-decoration: underline; }
main { padding-bottom: 64px; min-height: 60vh; }
.site-foot { border-top: 1px solid var(--line); padding-top: 24px; padding-bottom: 40px; display: flex; justify-content: space-between; gap: 1em; flex-wrap: wrap; color: var(--muted); font-size: 0.9rem; }
.site-foot p { margin: 0; }

.intro .lead { font-size: clamp(1.05rem, 2vw, 1.3rem); color: var(--muted); margin: 0.6em 0 0; }

.grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr)); gap: var(--gap); }
@media (max-width: 520px) { .grid { grid-template-columns: 1fr 1fr; gap: 16px 12px; } }
.card { text-decoration: none; display: block; }
.card-img { aspect-ratio: 4 / 5; background: var(--soft); display: flex; align-items: center; justify-content: center; overflow: hidden; }
.card-img img { width: 100%; height: 100%; object-fit: cover; transition: transform .4s ease; }
.card:hover .card-img img { transform: scale(1.02); }
.card-txt { display: flex; flex-direction: column; padding-top: 8px; font-size: 0.92rem; line-height: 1.35; }
.card-title { font-style: italic; }
.card-meta { color: var(--muted); font-size: 0.85rem; margin-top: 2px; }
.card.out .card-img { opacity: .45; filter: grayscale(1); }
.card.out .card-txt { color: var(--muted); }
.more { margin-top: 2.5em; }

.focus-link { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: var(--gap); text-decoration: none; align-items: end; }
.focus-img { background: var(--soft); }
.focus-img img { width: 100%; max-height: 70vh; object-fit: contain; }
.focus-title { font-size: 1.4rem; font-style: italic; margin: 0 0 .2em; }
@media (max-width: 700px) { .focus-link { grid-template-columns: 1fr; } }

.filters { display: flex; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: var(--gap); }
select, input, textarea, button { font: inherit; color: inherit; }
select, input:not([type=checkbox]):not([type=radio]), textarea { border: 1px solid var(--line); border-radius: 2px; padding: 8px 10px; background: #fff; max-width: 100%; }
button, .btn { border: 1px solid var(--ink); background: var(--ink); color: #fff; padding: 8px 16px; border-radius: 2px; cursor: pointer; text-decoration: none; display: inline-block; }
button.ghost, .btn.ghost { background: transparent; color: var(--ink); }
button.link { background: none; border: none; color: inherit; padding: 0; text-decoration: underline; text-underline-offset: 3px; }
button:disabled { opacity: .45; cursor: not-allowed; }
.check { display: inline-flex; gap: 6px; align-items: center; }

.work { display: grid; grid-template-columns: minmax(0, 3fr) minmax(0, 2fr); gap: calc(var(--gap) * 1.5); margin-top: 1em; }
.work-photos { display: flex; flex-direction: column; gap: var(--gap); }
.work-photos img { background: var(--soft); width: 100%; }
.work-info { position: sticky; top: 24px; align-self: start; }
.work-info h1 { font-style: italic; margin-bottom: .2em; }
.work-artist { margin: 0 0 1.2em; }
.facts { list-style: none; padding: 0; margin: 0 0 1.2em; color: var(--muted); }
.price { font-size: 1.4rem; margin: 1em 0 0; }
.avail { margin: 1em 0; }
.avail.out { color: var(--muted); }
.cta { width: 100%; padding: 12px; }
@media (max-width: 800px) { .work { grid-template-columns: 1fr; } .work-info { position: static; } }

.artist-list { list-style: none; padding: 0; columns: 2 260px; }
.artist-list li { padding: 6px 0; break-inside: avoid; }
.artist-list a { text-decoration: none; }
.artist-list a:hover span:first-child { text-decoration: underline; }
.artist { display: flex; gap: var(--gap); align-items: flex-start; margin: 1em 0; flex-wrap: wrap; }
.portrait { width: 220px; aspect-ratio: 1; object-fit: cover; background: var(--soft); }
.artist > div { flex: 1 1 320px; max-width: 40em; }
.links { display: flex; gap: 1.2em; }

.prose { max-width: 38em; }
.prose.narrow { max-width: 26em; margin-top: 2em; }
.stack { display: flex; flex-direction: column; gap: 14px; }
.stack label { display: flex; flex-direction: column; gap: 4px; }
.stack label.check { flex-direction: row; }
.dev { background: #fff6d6; padding: 10px; font-size: .85rem; word-break: break-all; }

a.btn.cta { text-align: center; }
.error { background: #fbe9e7; padding: 8px 12px; }
.flash { background: #e9f5ea; padding: 8px 12px; }
.subnav { display: flex; gap: 1.2em; flex-wrap: wrap; align-items: center; border-bottom: 1px solid var(--line); padding: 10px 0; margin-bottom: 1em; font-size: .95rem; }
.subnav form { margin: 0; }
.rows { list-style: none; padding: 0; margin: 0; }
.rows li { padding: 12px 0; border-bottom: 1px solid var(--line); }
.rows.thumbs li { display: flex; gap: 12px; align-items: flex-start; }
.thumb { width: 56px; height: 56px; flex: none; background: var(--soft); }
.thumb img, .thumb span { width: 56px; height: 56px; object-fit: cover; display: block; }
.grow { flex: 1; min-width: 0; }
.actions { display: flex; gap: 12px; align-items: center; flex-wrap: wrap; margin: 1.2em 0; }
.actions.tight { gap: 6px; margin: .5em 0 0; }
.actions form { margin: 0; }
button.small { padding: 4px 10px; font-size: .85rem; }
.compare { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; margin: 6px 0; }
.compare > div { background: var(--soft); padding: 8px; min-width: 0; overflow-wrap: anywhere; }
.compare p { margin: 4px 0 0; }
.facts-list dt { color: var(--muted); font-size: .85rem; margin-top: .8em; }
.facts-list dd { margin: 0; }
pre { white-space: pre-wrap; font: inherit; background: var(--soft); padding: 8px; }
.stack input:not([type=checkbox]):not([type=radio]), .stack textarea, .stack select { width: 100%; }
.stack label.check { align-items: flex-start; }
.stack label.check input { margin-top: 5px; }
.prose.wide { max-width: 44em; }
.form fieldset, .work-block { border: 1px solid var(--line); padding: 16px; display: flex; flex-direction: column; gap: 14px; margin: 0 0 16px; min-width: 0; }
.form legend { padding: 0 6px; color: var(--muted); font-size: .9rem; }
.cols { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.cols.three { grid-template-columns: 1fr 1fr 1fr; }
.cols > label { min-width: 0; }
.field { display: flex; gap: 14px; flex-wrap: wrap; align-items: center; }
.field > span { width: 100%; }
.photo-row { display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 6px; }
.photo-row img { width: 96px; height: 96px; object-fit: cover; background: var(--soft); }
.work-series { margin: -0.8em 0 1.2em; color: var(--muted); }
.series-list { list-style: none; padding: 0; margin: 0 0 1em; }
.series-list li { padding: 6px 0; }
.series-head { max-width: 40em; margin-bottom: 2em; }
.series-title { font-size: clamp(1.5rem, 3vw, 2rem); margin: 0 0 .2em; }
.series-text { margin-top: 1em; }
.series-block { border: 1px solid var(--line); padding: 16px; display: flex; flex-direction: column; gap: 14px; margin: 0 0 16px; min-width: 0; }
.tirage-note.warn { color: #a33; }
.steps { padding-left: 1.2em; }
.steps li { margin: 0 0 1.4em; }
.steps li.done b::after { content: " ✓"; }
.portrait-box { display: flex; gap: 16px; align-items: center; margin: .8em 0; flex-wrap: wrap; }
.portrait-box img, .portrait-mini { width: 96px; height: 96px; object-fit: cover; background: var(--soft); }
.btn.ghost { background: transparent; color: var(--ink); }
.signature { margin-top: 2em; border-top: 1px solid var(--ink); padding-top: 1em; }
.uploading { opacity: .5; pointer-events: none; }
.phone-field { display: flex; flex-direction: column; gap: 4px; }
.phone-row { display: flex; gap: 8px; }
.phone-row select { flex: 0 0 auto; width: auto !important; max-width: 48%; }
.phone-row input { flex: 1; min-width: 0; }

/* Pages de texte (manifeste, comment acheter, conditions…) */
body:not(.admin) main h1.page-title {
  display: block; text-transform: none; letter-spacing: -0.015em; border: 0; padding: 0;
  font-size: clamp(2rem, 5vw, 3.2rem); line-height: 1.05; margin: 1.2em 0 0.8em;
}
.text-page { max-width: 40em; }
.text-page > h1 + p { font-size: clamp(1.1rem, 2vw, 1.3rem); line-height: 1.45; }
.text-page h2 {
  font-size: clamp(1.25rem, 2.4vw, 1.55rem); font-weight: 400; letter-spacing: -0.01em;
  margin: 2.2em 0 0.6em; padding-top: 0.7em; border-top: 1px solid var(--ink);
}
.text-page ul { padding-left: 1.1em; }
.text-page li { margin: 0.35em 0; }
.text-page li::marker { color: var(--muted); }

/* En-tête : logo, puis menu étalé sur toute la largeur, un peu plus présent */
.site-head { flex-direction: column; align-items: stretch; gap: 14px; }
.site-head .logo { align-self: flex-start; }
.site-head nav {
  display: flex; justify-content: space-between; flex-wrap: wrap; gap: 6px 18px;
  font-size: clamp(1rem, 1.6vw, 1.2rem); font-weight: 500; letter-spacing: 0.01em;
  border-top: 1px solid var(--ink); padding-top: 10px;
}
@media (max-width: 520px) { .site-head nav { justify-content: flex-start; gap: 6px 20px; } }
.head-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; }
.tagline { margin: 4px 0 0; color: var(--muted); text-align: right; max-width: 18em; font-size: clamp(.9rem, 1.4vw, 1.05rem); line-height: 1.35; }
/* L'accueil commence directement par les nouveautés : pas de second filet collé au menu */
main > section:first-child > .kicker:first-child { margin-top: 1.6em; }
/* Carte de série : pièces superposées, une seule visible, fondu entre elles */
.slides { position: relative; }
.slides img { position: absolute; inset: 0; opacity: 0; transition: opacity .9s ease; }
.slides img.on { opacity: 1; }
.series-card .card-meta { color: var(--ink); }
.slides img { transition: opacity 1.2s ease; }
.slide-arrow { position: absolute; top: 50%; transform: translateY(-50%); z-index: 2; width: 36px; height: 36px; padding: 0;
  border: 0; border-radius: 50%; background: rgba(255,255,255,.85); color: var(--ink); font-size: 1.4rem; line-height: 1; cursor: pointer; opacity: .75; }
.slide-arrow:hover, .slide-arrow:focus-visible { opacity: 1; }
.slide-arrow.prev { left: 8px; } .slide-arrow.next { right: 8px; }
.notice { border: 1px solid var(--ink); padding: 18px 20px; margin: 1.5em 0 2em; background: var(--soft); }
.notice p { margin: 0 0 .7em; }
.notice p:last-child { margin-bottom: 0; }
.notice-title { font-size: .78rem; letter-spacing: .14em; text-transform: uppercase; }
/* Proposer : photos des œuvres */
.photo-manager { display: flex; flex-direction: column; gap: 8px; }
.photo-list { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 10px; }
.photo-list li { position: relative; width: 110px; cursor: grab; }
.photo-list img { width: 110px; height: 110px; object-fit: cover; display: block; background: var(--soft); border: 1px solid var(--line); }
.photo-list li:first-child img { border-color: var(--ink); }
.photo-tag { position: absolute; top: 4px; left: 4px; background: rgba(255,255,255,.9); font-size: .72rem; padding: 1px 5px; }
.photo-tools { display: flex; justify-content: space-between; margin-top: 4px; }
.photo-tools button { background: none; color: var(--ink); border: 1px solid var(--line); padding: 0 8px; font-size: .95rem; line-height: 1.6; }
.photo-tools button:disabled { opacity: .3; }
.photo-add { align-self: flex-start; }
.photo-add[hidden] { display: none; }
.portrait-pick { display: flex; flex-direction: column; gap: 8px; align-items: flex-start; }
.portrait-preview { width: 120px; height: 120px; object-fit: cover; border: 1px solid var(--line); }
.guide ol { margin: .4em 0 .6em; padding-left: 1.2em; }
.guide li { margin: .25em 0; }
.photo-list li { list-style: none; }
form.work-block { border: 0; padding: 0; }
