:root {
  --cream: #F7F2EA; --paper: #FFFDF9; --sand: #EFE6D8; --line: #E4D9C7;
  --ink: #26241F; --muted: #6E685C;
  --olive: #576444; --olive-deep: #3F4A30; --olive-soft: #E6E9DC;
  --red: #C62B2B; --red-deep: #A51F24; --brass: #B08D57;
  --wa: #1FA855; --wa-deep: #168A45;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(38,36,31,.06), 0 10px 28px rgba(38,36,31,.10);
  --serif: 'Fraunces', Georgia, 'Times New Roman', serif;
  --sans: 'DM Sans', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; color: var(--ink); font: 16px/1.55 var(--sans); -webkit-font-smoothing: antialiased;
  background-color: var(--cream);
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='180' height='180'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='2' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 .2  0 0 0 0 .16  0 0 0 0 .1  0 0 0 .045 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}
body.modal-open { overflow: hidden; }
img { max-width: 100%; display: block; }
a { color: inherit; }
button { font: inherit; color: inherit; }
:focus-visible { outline: 2px solid var(--olive); outline-offset: 2px; border-radius: 6px; }
.wrap { width: min(1180px, 100% - 32px); margin-inline: auto; }
.muted { color: var(--muted); }
.small { font-size: 14px; }
.tiny { font-size: 12.5px; }
.center { text-align: center; }
.eyebrow { font-size: 12px; letter-spacing: .18em; text-transform: uppercase; color: var(--olive); font-weight: 700; margin: 0 0 10px; }
h2 { font-family: var(--serif); font-weight: 600; font-size: clamp(28px, 5.5vw, 40px); line-height: 1.1; margin: 0; letter-spacing: -.005em; }
.h3 { font-size: clamp(24px, 4.5vw, 30px); margin-bottom: 18px; }
.linkish { background: none; border: 0; padding: 0; color: inherit; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }

/* Bandeau maquette */
.ribbon { background: var(--olive-deep); color: #EFE9DC; font-size: 12.5px; line-height: 1.4; padding: 6px 16px; display: flex; gap: 2px 14px; justify-content: center; align-items: center; flex-wrap: wrap; text-align: center; position: relative; z-index: 60; }
.ribbon b { letter-spacing: .16em; }
.rib-note { opacity: .8; font-size: 11.5px; flex-basis: 100%; }
@media (min-width: 760px) { .rib-note { flex-basis: auto; } }
.ribbon a { color: #fff; text-decoration: none; opacity: .75; padding: 2px 2px; }
.ribbon a.on { opacity: 1; font-weight: 700; border-bottom: 1.5px solid #fff; }

/* Boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 999px; padding: 12px 22px; min-height: 48px; font-weight: 600; font-size: 15.5px; cursor: pointer; text-decoration: none; transition: transform .15s, background-color .2s, box-shadow .2s; white-space: nowrap; }
.btn:active { transform: scale(.98); }
.btn-primary { background: var(--olive); color: #fff; }
.btn-primary:hover { background: var(--olive-deep); }
.btn-ghost { background: transparent; box-shadow: inset 0 0 0 1.5px var(--ink); color: var(--ink); }
.btn-ghost:hover { background: rgba(38,36,31,.05); }
.btn-wa { background: var(--wa); color: #fff; }
.btn-wa:hover { background: var(--wa-deep); }
.btn-block { width: 100%; }
.btn-lg { min-height: 56px; font-size: 17px; }
.btn-sm { min-height: 40px; padding: 8px 16px; font-size: 14.5px; }
.btn[disabled] { opacity: .5; cursor: not-allowed; transform: none; }
.icon-btn { width: 44px; height: 44px; flex: none; border-radius: 50%; border: 0; background: transparent; display: grid; place-items: center; cursor: pointer; text-decoration: none; color: inherit; }
.icon-btn:hover { background: rgba(38,36,31,.06); }

/* En-tête du site */
.site-header { position: sticky; top: 0; z-index: 30; background: rgba(247,242,234,.9); -webkit-backdrop-filter: saturate(1.2) blur(10px); backdrop-filter: saturate(1.2) blur(10px); border-bottom: 1px solid var(--line); }
.hdr { display: flex; align-items: center; gap: 16px; height: 68px; }
.brand img { height: 40px; width: auto; }
.nav-desktop { display: none; gap: 28px; margin-left: auto; font-weight: 500; font-size: 15px; }
.nav-desktop a { text-decoration: none; opacity: .8; }
.nav-desktop a:hover { opacity: 1; color: var(--olive); }
.hdr-actions { margin-left: auto; display: flex; gap: 4px; align-items: center; }
@media (min-width: 900px) { .nav-desktop { display: flex; } .hdr-actions { margin-left: 24px; } .menu-btn { display: none; } }
@media (max-width: 380px) { .hdr-actions .btn span { display: none; } .hdr-actions .btn { padding: 8px 12px; } }

/* Accueil */
.hero { display: grid; gap: 34px; padding: 30px 0 52px; }
.hero h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(38px, 9vw, 64px); line-height: 1.02; letter-spacing: -.015em; margin: 0 0 16px; }
.hero h1 em { font-style: italic; font-weight: 400; color: var(--red); }
.lead { font-size: 17.5px; color: var(--muted); max-width: 36ch; margin: 0 0 24px; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.hero-points { list-style: none; padding: 0; margin: 22px 0 0; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14.5px; color: var(--muted); }
.hero-points li::before { content: '✦'; color: var(--brass); margin-right: 7px; }
.hero-collage { position: relative; margin-right: 8px; }
.hero-collage figure { margin: 0; border-radius: 18px; overflow: hidden; box-shadow: var(--shadow); background: var(--sand); }
.hero-collage img { width: 100%; height: 100%; object-fit: cover; }
.hero-collage .c1 { aspect-ratio: 4 / 4.4; }
.hero-collage .c2 { position: absolute; width: 40%; aspect-ratio: 1; right: -8px; bottom: -24px; border: 6px solid var(--paper); transform: rotate(4deg); }
.hero-collage .c3 { display: none; }
.hero-collage .hero-tag { position: absolute; left: 14px; top: 14px; }
@media (min-width: 900px) {
  .hero { grid-template-columns: 1.05fr 1fr; align-items: center; gap: 56px; padding: 60px 0 84px; }
  .hero-collage { height: 560px; margin-right: 0; }
  .hero-collage .c1 { position: absolute; left: 0; top: 0; width: 64%; height: 90%; aspect-ratio: auto; }
  .hero-collage .c2 { width: 46%; right: 0; bottom: 0; }
  .hero-collage .c3 { display: block; position: absolute; width: 34%; aspect-ratio: 3 / 4; right: 5%; top: 0; border: 6px solid var(--paper); transform: rotate(-4deg); }
}

/* Étiquette « Pièce unique » (façon étiquette de brocante) */
.tag-unique { display: inline-flex; align-items: center; background: var(--paper); color: var(--ink); font: 700 11.5px/1 var(--sans); letter-spacing: .12em; text-transform: uppercase; padding: 8px 12px 8px 24px; position: relative; clip-path: polygon(11px 0, 100% 0, 100% 100%, 11px 100%, 0 50%); border-radius: 0 6px 6px 0; box-shadow: 0 1px 3px rgba(0,0,0,.12); }
.tag-unique::before { content: ''; position: absolute; left: 11px; top: 50%; width: 6px; height: 6px; border-radius: 50%; background: var(--cream); box-shadow: inset 0 0 0 1.5px var(--brass); transform: translateY(-50%); }
.tag-chip { display: inline-flex; align-items: center; font-size: 11.5px; font-weight: 700; letter-spacing: .1em; text-transform: uppercase; padding: 7px 11px; border-radius: 999px; background: var(--ink); color: var(--cream); }
.tag-chip.new { background: var(--olive); color: #fff; }

/* Bande « carreaux de ciment » (le sol de sa boutique) */
.tiles { height: 22px; background-color: #FBF9F4; background-image: linear-gradient(45deg, transparent 45%, #1F1E1B 45% 55%, transparent 55%), linear-gradient(-45deg, transparent 45%, #1F1E1B 45% 55%, transparent 55%); background-size: 22px 22px; border-block: 2px solid #1F1E1B; }

/* Sections */
.section { padding: 52px 0; }
.section-head { display: flex; align-items: flex-end; justify-content: space-between; gap: 12px; margin-bottom: 20px; flex-wrap: wrap; }
.band { background: var(--sand); }

/* Filtres */
.chips { display: flex; gap: 8px; overflow-x: auto; padding: 2px 16px 10px; margin: 0 -16px; scrollbar-width: none; }
.chips::-webkit-scrollbar { display: none; }
.chip { flex: none; border: 1.5px solid var(--line); background: var(--paper); border-radius: 999px; padding: 9px 15px; font-size: 14.5px; font-weight: 500; cursor: pointer; white-space: nowrap; transition: background-color .15s, border-color .15s; }
.chip:hover { border-color: #CDBFA8; }
.chip[aria-pressed="true"] { background: var(--ink); border-color: var(--ink); color: var(--cream); }
.chip .n { opacity: .55; margin-left: 5px; font-weight: 400; }
@media (min-width: 900px) { .chips { flex-wrap: wrap; overflow: visible; margin: 0; padding: 2px 0 10px; } }
.filter-row { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin: 8px 0 20px; font-size: 14.5px; }
.switch { display: inline-flex; align-items: center; gap: 10px; cursor: pointer; user-select: none; }
.switch input { appearance: none; -webkit-appearance: none; width: 42px; height: 24px; border-radius: 999px; background: #D8CFC0; position: relative; transition: background-color .2s; cursor: pointer; margin: 0; flex: none; }
.switch input::after { content: ''; position: absolute; top: 3px; left: 3px; width: 18px; height: 18px; border-radius: 50%; background: #fff; box-shadow: 0 1px 2px rgba(0,0,0,.2); transition: transform .2s; }
.switch input:checked { background: var(--olive); }
.switch input:checked::after { transform: translateX(18px); }
.select { appearance: none; -webkit-appearance: none; border: 1.5px solid var(--line); background: var(--paper) url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2326241F' stroke-width='2.2' stroke-linecap='round'><path d='M6 9l6 6 6-6'/></svg>") no-repeat right 12px center / 14px; border-radius: 999px; padding: 8px 34px 8px 14px; font: inherit; font-size: 14.5px; color: var(--ink); cursor: pointer; }

/* Grille de pièces */
.grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px 12px; }
@media (min-width: 640px) { .grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px 18px; } }
@media (min-width: 1024px) { .grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
.card { text-decoration: none; color: inherit; display: block; }
.card-media { position: relative; aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; background: var(--sand); }
.card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s ease; }
.card:hover .card-media img { transform: scale(1.045); }
.card.sold .card-media img { filter: saturate(.5) brightness(.96); }
.card-body { padding: 10px 2px 0; }
.card-cat { font-size: 11px; letter-spacing: .14em; text-transform: uppercase; color: var(--olive); font-weight: 700; margin: 0 0 3px; }
.card-title { font-family: var(--serif); font-weight: 600; font-size: 16.5px; line-height: 1.25; margin: 0 0 4px; }
.card-price { margin: 0; font-weight: 600; font-size: 15px; }
.card-price.req, .price.req { color: var(--muted); font-weight: 500; font-style: italic; }
.badge { position: absolute; top: 10px; left: 10px; font-size: 10.5px; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; padding: 5px 9px; border-radius: 999px; }
.badge-new { background: var(--olive); color: #fff; }
.badge-res { background: var(--brass); color: #fff; }
.stamp { position: absolute; left: 50%; top: 46%; transform: translate(-50%, -50%) rotate(-14deg); color: var(--red-deep); border: 3px solid currentColor; outline: 1.5px solid currentColor; outline-offset: -8px; border-radius: 8px; padding: 9px 16px 8px; font: 700 19px/1 var(--sans); letter-spacing: .24em; text-transform: uppercase; background: rgba(255,253,249,.8); pointer-events: none; }
.stamp-lg { font-size: 30px; padding: 14px 26px 12px; top: 42%; }
.empty-grid { grid-column: 1 / -1; text-align: center; padding: 40px 0; }

/* Comment acheter */
.steps { display: grid; gap: 14px; }
@media (min-width: 640px) { .steps { grid-template-columns: repeat(2, 1fr); gap: 18px; } }
@media (min-width: 1024px) { .steps { grid-template-columns: repeat(4, 1fr); gap: 20px; } }
.step { background: var(--paper); border: 1px solid var(--line); border-radius: var(--radius); padding: 22px; }
.step .num { width: 34px; height: 34px; border-radius: 50%; background: var(--olive); color: #fff; display: grid; place-items: center; font-weight: 700; margin-bottom: 14px; }
.step h3 { font-family: var(--serif); font-size: 20px; font-weight: 600; margin: 0 0 6px; }
.step p { margin: 0; color: var(--muted); font-size: 15px; }
.infos { display: grid; gap: 16px; margin-top: 26px; }
@media (min-width: 760px) { .infos { grid-template-columns: repeat(3, 1fr); } }
.info { display: flex; gap: 12px; align-items: flex-start; font-size: 15px; }
.info svg { flex: none; color: var(--olive); margin-top: 2px; }

/* À propos */
.about { display: grid; gap: 28px; align-items: center; }
@media (min-width: 900px) { .about { grid-template-columns: 1fr 1.1fr; gap: 64px; } }
.about-photo { border-radius: 20px; overflow: hidden; aspect-ratio: 4 / 4.2; box-shadow: var(--shadow); position: relative; }
.about-photo img { width: 100%; height: 100%; object-fit: cover; }
.about-photo .about-tag { position: absolute; left: 14px; bottom: 14px; }
.about p { font-size: 16.5px; }
.about blockquote { font-family: var(--serif); font-style: italic; font-size: 23px; line-height: 1.4; margin: 20px 0; padding-left: 18px; border-left: 3px solid var(--brass); }
.about-cta { display: flex; flex-wrap: wrap; gap: 10px; }
.site-footer .foot-muted { color: #C3CAAE; font-size: 14px; }
.site-footer .foot-hours { margin-top: 10px; font-size: 14px; color: #DCE1CC; }

/* Pied de page */
.site-footer { background: var(--olive-deep); color: #EFE9DC; padding: 44px 0 calc(28px + env(safe-area-inset-bottom)); }
.foot { display: grid; gap: 28px; }
@media (min-width: 760px) { .foot { grid-template-columns: 1.4fr 1fr 1fr 1fr; } }
.site-footer img { height: 44px; width: auto; margin-bottom: 12px; }
.site-footer h4 { font-size: 12px; letter-spacing: .16em; text-transform: uppercase; margin: 0 0 10px; color: #C3CAAE; }
.site-footer a, .site-footer .linkish { color: #fff; text-decoration: none; }
.site-footer p { margin: 0 0 6px; font-size: 15px; }
.foot-bottom { border-top: 1px solid rgba(255,255,255,.15); margin-top: 30px; padding: 16px 76px 0 0; font-size: 13px; color: #C3CAAE; display: flex; justify-content: space-between; flex-wrap: wrap; gap: 8px; }
.site-footer .credit { color: #fff; font-weight: 600; text-decoration: underline; text-decoration-color: rgba(255,255,255,.35); text-underline-offset: 3px; }
.site-footer .credit:hover { text-decoration-color: #fff; }
.fab-wa { position: fixed; right: 16px; bottom: calc(16px + env(safe-area-inset-bottom)); width: 58px; height: 58px; border-radius: 50%; background: var(--wa); color: #fff; display: grid; place-items: center; box-shadow: 0 8px 22px rgba(31,168,85,.42); border: 0; cursor: pointer; z-index: 45; }
.fab-wa svg { width: 28px; height: 28px; }

/* Fiche pièce */
.crumbs { padding: 16px 0 6px; font-size: 14.5px; }
.crumbs a { text-decoration: none; color: var(--muted); display: inline-flex; gap: 4px; align-items: center; }
.crumbs a:hover { color: var(--ink); }
.product { display: grid; gap: 24px; padding-bottom: 28px; }
@media (min-width: 900px) { .product { grid-template-columns: 1.1fr 1fr; gap: 52px; align-items: start; } .gallery { position: sticky; top: 90px; } }
.gallery { position: relative; }
.slides { display: flex; overflow-x: auto; scroll-snap-type: x mandatory; border-radius: 20px; background: var(--sand); scrollbar-width: none; aspect-ratio: 3 / 4; }
.slides::-webkit-scrollbar { display: none; }
.slide { flex: 0 0 100%; scroll-snap-align: center; }
.slide img { width: 100%; height: 100%; object-fit: contain; }
@media (min-width: 900px) { .slides { max-height: 76vh; margin-inline: auto; } }
.dots { display: flex; justify-content: center; gap: 6px; margin-top: 12px; }
.dots button { width: 8px; height: 8px; border-radius: 999px; border: 0; background: #CFC5B4; padding: 0; cursor: pointer; transition: width .2s; }
.dots button[aria-current="true"] { background: var(--ink); width: 22px; }
.thumbs { display: none; }
@media (min-width: 900px) {
  .thumbs { display: flex; gap: 10px; margin-top: 12px; }
  .thumbs button { width: 74px; height: 92px; border-radius: 10px; overflow: hidden; border: 2px solid transparent; padding: 0; cursor: pointer; background: var(--sand); }
  .thumbs button[aria-current="true"] { border-color: var(--ink); }
  .thumbs img { width: 100%; height: 100%; object-fit: cover; }
  .dots { display: none; }
}
.pinfo h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(30px, 6vw, 42px); line-height: 1.08; margin: 6px 0 14px; letter-spacing: -.01em; }
.price-row { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.price { font-size: 25px; font-weight: 700; }
.price.req { font-size: 21px; }
.status { font-size: 13px; font-weight: 600; padding: 5px 11px; border-radius: 999px; display: inline-flex; align-items: center; gap: 7px; }
.status::before { content: ''; width: 7px; height: 7px; border-radius: 50%; background: currentColor; }
.st-available { background: #E3EDD8; color: #3B6A28; }
.st-reserved { background: #F4E8D2; color: #87611F; }
.st-sold { background: #F6DDD9; color: var(--red-deep); }
.tags { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; margin-bottom: 18px; }
.desc { font-size: 16.5px; margin: 0 0 20px; }
.facts { margin: 0 0 24px; border-top: 1px solid var(--line); }
.facts div { display: flex; justify-content: space-between; gap: 16px; padding: 12px 0; border-bottom: 1px solid var(--line); font-size: 15px; }
.facts dt { color: var(--muted); }
.facts dd { margin: 0; font-weight: 600; text-align: right; }
.cta-stack { display: grid; gap: 10px; }
.sold-note { margin: 0 0 4px; font-weight: 600; }
.reassure { list-style: none; padding: 0; margin: 20px 0 0; display: grid; gap: 10px; font-size: 14.5px; color: var(--muted); }
.reassure li { display: flex; gap: 10px; align-items: center; }
.reassure svg { color: var(--olive); flex: none; }
.sticky-cta { display: none; }
@media (max-width: 899px) {
  .page-product .fab-wa { display: none; }
  .page-product .sticky-cta { display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 40; gap: 12px; align-items: center; justify-content: space-between; padding: 10px 16px calc(10px + env(safe-area-inset-bottom)); background: rgba(255,253,249,.97); border-top: 1px solid var(--line); box-shadow: 0 -6px 20px rgba(0,0,0,.06); }
  .page-product main { padding-bottom: 76px; }
  .sticky-cta div { min-width: 0; display: grid; }
  .sc-title { font-size: 13px; color: var(--muted); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
  .sc-price { font-weight: 700; font-size: 15px; white-space: nowrap; }
}

/* Fenêtres (feuilles) */
.backdrop { position: fixed; inset: 0; background: rgba(20,18,14,.5); display: flex; align-items: flex-end; justify-content: center; z-index: 100; animation: fade .2s ease; }
.sheet { background: var(--paper); width: 100%; max-width: 460px; max-height: 92vh; overflow-y: auto; border-radius: 24px 24px 0 0; padding: 16px 18px calc(22px + env(safe-area-inset-bottom)); box-shadow: 0 -10px 40px rgba(0,0,0,.2); animation: up .28s ease; }
@media (min-width: 640px) { .backdrop { align-items: center; } .sheet { border-radius: 24px; padding-bottom: 22px; } }
.sheet-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; gap: 12px; }
.sheet-head h3 { font-family: var(--serif); font-size: 22px; font-weight: 600; margin: 0; }
.menu-links { display: grid; margin: 4px 0 18px; }
.menu-links a { font-family: var(--serif); font-size: 24px; text-decoration: none; padding: 12px 2px; border-bottom: 1px solid var(--line); }
.wa-chat { background: #EFE7DD; border-radius: 16px; padding: 12px; margin-bottom: 12px; }
.wa-top { display: flex; align-items: center; gap: 10px; font-size: 13.5px; line-height: 1.3; margin-bottom: 12px; color: #2F2F2F; }
.wa-avatar { width: 38px; height: 38px; border-radius: 50%; background: #fff; display: grid; place-items: center; overflow: hidden; flex: none; }
.wa-avatar img { width: 32px; }
.wa-bubble { background: #D9FDD3; border-radius: 12px 12px 4px 12px; padding: 6px 6px 22px; font-size: 14.5px; line-height: 1.45; margin-left: auto; max-width: 94%; position: relative; box-shadow: 0 1px 1px rgba(0,0,0,.1); color: #111; }
.wa-bubble .wa-text { padding: 4px 6px 0; }
.wa-preview { display: flex; gap: 10px; background: rgba(0,0,0,.05); border-radius: 8px; overflow: hidden; margin-bottom: 4px; }
.wa-preview img { width: 64px; height: 64px; object-fit: cover; flex: none; }
.wa-preview div { display: grid; align-content: center; font-size: 13px; line-height: 1.3; padding-right: 8px; }
.wa-preview span { color: #555; font-size: 12px; }
.wa-time { position: absolute; right: 10px; bottom: 4px; font-size: 11px; color: #667781; }
#toast { position: fixed; left: 50%; bottom: calc(92px + env(safe-area-inset-bottom)); transform: translate(-50%, 16px); background: var(--ink); color: #fff; padding: 12px 16px; border-radius: 14px; font-size: 14.5px; display: flex; gap: 16px; align-items: center; opacity: 0; pointer-events: none; transition: opacity .25s, transform .25s; z-index: 200; width: max-content; max-width: calc(100% - 32px); box-shadow: 0 10px 30px rgba(0,0,0,.25); }
#toast.show { opacity: 1; transform: translate(-50%, 0); pointer-events: auto; }
#toast button { background: none; border: 0; color: #CFE3B5; font-weight: 700; cursor: pointer; padding: 0; flex: none; }
@keyframes fade { from { opacity: 0; } }
@keyframes up { from { transform: translateY(40px); opacity: .5; } }

/* ============ Appli de gestion ============ */
body.admin { height: 100vh; height: 100dvh; display: flex; flex-direction: column; overflow: hidden; }
body.admin #app { flex: 1; min-height: 0; display: flex; }
.admin-page { flex: 1; min-height: 0; display: flex; justify-content: center; align-items: stretch; gap: 56px; }
.phone { width: 100%; height: 100%; background: var(--cream); display: flex; flex-direction: column; position: relative; overflow: hidden; }
.admin-aside { display: none; }
@media (min-width: 760px) {
  .admin-page { align-items: center; padding: 24px 16px; background: radial-gradient(1200px 600px at 30% 20%, #EFE6D5, transparent 70%), var(--sand); }
  .phone { width: 390px; height: min(820px, 100%); border-radius: 46px; border: 11px solid #1C1B19; box-shadow: 0 30px 60px rgba(0,0,0,.22), 0 0 0 1px #000; flex: none; }
}
@media (min-width: 1080px) {
  .admin-aside { display: block; max-width: 360px; }
  .admin-aside h2 { font-size: 34px; margin-bottom: 16px; }
  .aside-list { padding-left: 20px; margin: 0 0 24px; display: grid; gap: 10px; color: var(--muted); }
}
.app-bar { display: flex; align-items: center; gap: 6px; padding: 12px 12px 8px; background: rgba(247,242,234,.96); flex: none; z-index: 5; min-height: 60px; }
.app-bar h1 { font-size: 18px; margin: 0; font-weight: 700; }
.app-logo { height: 30px; width: auto; margin-left: 6px; }
.avatar { margin-left: auto; width: 36px; height: 36px; border-radius: 50%; background: var(--olive); color: #fff; display: grid; place-items: center; font-weight: 700; margin-right: 4px; }
.app-main { flex: 1; min-height: 0; overflow-y: auto; padding: 4px 16px 24px; -webkit-overflow-scrolling: touch; }
.tabbar { flex: none; display: grid; grid-template-columns: 1fr auto 1fr; align-items: center; padding: 6px 28px calc(10px + env(safe-area-inset-bottom)); background: var(--paper); border-top: 1px solid var(--line); }
.tab { display: grid; justify-items: center; gap: 2px; font-size: 11.5px; font-weight: 600; color: var(--muted); text-decoration: none; padding: 4px; }
.tab.on { color: var(--olive); }
.tab-add { width: 58px; height: 58px; border-radius: 50%; background: var(--olive); color: #fff; display: grid; place-items: center; margin-top: -24px; box-shadow: 0 8px 20px rgba(87,100,68,.45); text-decoration: none; border: 4px solid var(--paper); }
.tab-add svg { width: 26px; height: 26px; }

.login { flex: 1; display: flex; flex-direction: column; justify-content: center; padding: 32px 24px; text-align: center; gap: 12px; }
.login img { width: 190px; margin: 0 auto 22px; }
.login h1 { font-family: var(--serif); font-size: 34px; font-weight: 600; margin: 0; }
.login .btn { margin-top: 18px; }
.secure-note { display: inline-flex; gap: 6px; align-items: center; justify-content: center; font-size: 13.5px; color: var(--muted); margin: 18px 0 0; }
.faceid-overlay { position: absolute; inset: 0; background: rgba(20,18,14,.35); display: grid; place-items: center; z-index: 50; animation: fade .2s; }
.faceid-box { background: rgba(255,253,249,.96); border-radius: 26px; width: 150px; height: 150px; display: grid; place-items: center; align-content: center; gap: 8px; font-weight: 600; }
.faceid-box svg { width: 60px; height: 60px; color: var(--ink); animation: pulse .9s ease-in-out infinite; }
.faceid-overlay.ok svg { color: var(--wa); animation: none; }
@keyframes pulse { 50% { transform: scale(.9); opacity: .7; } }

.greet h1 { font-family: var(--serif); font-size: 30px; font-weight: 600; margin: 4px 0 0; }
.greet p { margin: 0; }
.kpis { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin: 16px 0; }
.kpi { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 10px 12px; }
.kpi b { display: block; font-size: 24px; font-family: var(--serif); line-height: 1.1; }
.kpi span { font-size: 12.5px; color: var(--muted); }
.seg { display: flex; background: #EBE3D6; border-radius: 12px; padding: 3px; gap: 3px; margin: 18px 0 12px; }
.seg button { flex: 1; border: 0; background: transparent; border-radius: 9px; padding: 8px 4px; font-size: 13.5px; font-weight: 600; color: var(--muted); cursor: pointer; }
.seg button .n { opacity: .6; font-weight: 500; }
.seg button[aria-pressed="true"] { background: var(--paper); color: var(--ink); box-shadow: 0 1px 3px rgba(0,0,0,.1); }
.plist { list-style: none; margin: 0; padding: 0; display: grid; gap: 10px; }
.pitem { background: var(--paper); border: 1px solid var(--line); border-radius: 16px; padding: 10px; display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 10px 12px; align-items: center; }
.pitem img { width: 56px; height: 68px; border-radius: 10px; object-fit: cover; }
.pmeta b { display: block; font-size: 14.5px; line-height: 1.3; }
.pmeta span { font-size: 12.5px; color: var(--muted); }
.status-seg { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, 1fr); gap: 6px; }
.status-seg button { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; padding: 8px 4px; font-size: 13px; font-weight: 600; color: var(--muted); cursor: pointer; transition: background-color .15s, border-color .15s; }
.status-seg .s-available[aria-pressed="true"] { background: #E3EDD8; border-color: #9DBB85; color: #33601F; }
.status-seg .s-reserved[aria-pressed="true"] { background: #F4E8D2; border-color: #D8B579; color: #7D5A1E; }
.status-seg .s-sold[aria-pressed="true"] { background: #F6DDD9; border-color: #E09A91; color: var(--red-deep); }
.empty { text-align: center; color: var(--muted); padding: 30px 0; }

.fsec { margin: 0 0 20px; }
.flabel { display: block; font-weight: 700; font-size: 14.5px; margin: 0 0 8px; }
.flabel .muted { font-weight: 400; }
.photo-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.photo-add { aspect-ratio: 1; border: 2px dashed #C6B9A2; border-radius: 14px; display: grid; place-items: center; align-content: center; gap: 4px; text-align: center; font-size: 12.5px; font-weight: 600; color: var(--olive); cursor: pointer; background: var(--paper); padding: 8px; }
.photo-add.first { grid-column: 1 / -1; aspect-ratio: auto; padding: 30px 12px; font-size: 15px; }
.sample { grid-column: 1 / -1; justify-self: center; font-size: 13.5px; color: var(--muted); margin-top: 2px; }
.ph { position: relative; aspect-ratio: 1; border-radius: 14px; overflow: hidden; background: var(--sand); animation: fade .3s; }
.ph:first-child { grid-column: span 2; grid-row: span 2; }
.ph img { width: 100%; height: 100%; object-fit: cover; }
.main-lbl { position: absolute; left: 8px; bottom: 8px; background: rgba(0,0,0,.62); color: #fff; font-size: 11px; font-weight: 600; padding: 3px 8px; border-radius: 999px; }
.ph .rm, .ph .make-main { position: absolute; top: 6px; width: 28px; height: 28px; border-radius: 50%; border: 0; background: rgba(0,0,0,.55); color: #fff; cursor: pointer; display: grid; place-items: center; padding: 0; }
.ph .rm { right: 6px; }
.ph .make-main { left: 6px; }
.ph .rm svg { width: 15px; height: 15px; }
.compress-note { font-size: 12.5px; color: #33601F; background: #E8F0DD; border-radius: 10px; padding: 8px 10px; margin: 10px 0 0; display: none; align-items: center; gap: 6px; }
.compress-note svg { width: 16px; height: 16px; flex: none; }
.form input[type="text"], .form textarea { width: 100%; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; padding: 13px 14px; font: inherit; font-size: 16px; color: var(--ink); }
.form textarea { resize: vertical; min-height: 96px; }
.form input:focus, .form textarea:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 3px rgba(87,100,68,.15); }
.price-input { display: flex; align-items: center; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; padding-right: 14px; }
.price-input:focus-within { border-color: var(--olive); box-shadow: 0 0 0 3px rgba(87,100,68,.15); }
.form .price-input input { border: 0; box-shadow: none; font-size: 22px; font-weight: 700; padding: 11px 14px; flex: 1; min-width: 0; background: transparent; }
.form .price-input input:disabled { color: #B5AC9C; }
.price-input span { font-weight: 700; color: var(--muted); }
.check { display: flex; align-items: center; gap: 8px; margin-top: 10px; font-size: 14.5px; cursor: pointer; }
.qty-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.qty-row .flabel { margin: 0; }
.qty { display: inline-flex; align-items: center; flex: none; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; overflow: hidden; }
.qty:focus-within { border-color: var(--olive); box-shadow: 0 0 0 3px rgba(87,100,68,.15); }
.qty button { width: 44px; height: 46px; border: 0; background: transparent; font-size: 22px; font-weight: 600; color: var(--olive); cursor: pointer; }
.form .qty input[type="text"] { width: 52px; border: 0; border-radius: 0; box-shadow: none; padding: 10px 0; text-align: center; font-size: 18px; font-weight: 700; background: transparent; }
.check input { width: 18px; height: 18px; accent-color: var(--olive); }
.chips-select { flex-wrap: wrap; overflow: visible; margin: 0; padding: 0; }
.btn-ai { width: 100%; border: 1.5px dashed var(--brass); background: #FBF4E8; color: #7B5E2C; border-radius: 14px; padding: 12px; font-weight: 700; display: flex; align-items: center; justify-content: center; gap: 8px; cursor: pointer; margin: 0 0 22px; }
.btn-ai.loading { background: linear-gradient(90deg, #FBF4E8, #F3E4C8, #FBF4E8); background-size: 200% 100%; animation: shimmer 1.1s linear infinite; }
@keyframes shimmer { to { background-position: -200% 0; } }
.pill { font-size: 10px; letter-spacing: .08em; text-transform: uppercase; background: var(--brass); color: #fff; border-radius: 999px; padding: 3px 7px; }
details.more { border-top: 1px solid var(--line); border-bottom: 1px solid var(--line); }
details.more summary { cursor: pointer; font-weight: 700; list-style: none; display: flex; align-items: center; justify-content: space-between; padding: 14px 0; }
details.more summary::-webkit-details-marker { display: none; }
details.more summary::after { content: '+'; font-size: 22px; font-weight: 400; color: var(--muted); }
details.more[open] summary::after { content: '–'; }
.more-body { padding-bottom: 16px; display: grid; gap: 10px; }
.more-body .flabel { margin-top: 6px; }
.dims { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.form-bar { position: sticky; bottom: -24px; display: grid; grid-template-columns: 1fr 1.6fr; gap: 10px; padding: 14px 0 18px; margin-bottom: -24px; background: linear-gradient(to top, var(--cream) 75%, rgba(247,242,234,0)); }
.err { color: var(--red-deep); font-size: 13px; margin: 6px 0 0; }
.phone-overlay { position: absolute; inset: 0; background: rgba(20,18,14,.45); display: flex; align-items: flex-end; z-index: 40; animation: fade .2s; }
.phone-sheet { background: var(--paper); width: 100%; border-radius: 26px 26px 0 0; padding: 22px 18px calc(22px + env(safe-area-inset-bottom)); text-align: center; animation: up .3s ease; }
.phone-sheet h3 { font-family: var(--serif); font-size: 26px; font-weight: 600; margin: 8px 0 6px; }
.phone-sheet .ok { color: var(--wa); display: grid; place-items: center; }
.phone-sheet .btn { margin-top: 10px; }
.settings { list-style: none; padding: 0; margin: 8px 0 20px; background: var(--paper); border: 1px solid var(--line); border-radius: 16px; overflow: hidden; }
.settings li + li { border-top: 1px solid var(--line); }
.settings button { width: 100%; display: flex; align-items: center; gap: 12px; background: none; border: 0; padding: 14px; cursor: pointer; text-align: left; }
.settings .s-ico { width: 34px; height: 34px; border-radius: 10px; background: var(--olive-soft); color: var(--olive); display: grid; place-items: center; flex: none; }
.settings .s-txt { flex: 1; min-width: 0; display: grid; }
.settings .s-txt b { font-size: 15px; font-weight: 600; }
.settings .s-txt span { font-size: 13px; color: var(--muted); }
.settings .chev { color: #B5AC9C; }
.app-h1 { font-family: var(--serif); font-size: 30px; font-weight: 600; margin: 4px 0 4px; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

/* ===== Ajouts du site final ===== */
[id] { scroll-margin-top: 84px; }
.sheet-logo { height: 32px; width: auto; }
.empty-shop { text-align: center; padding: 48px 16px; background: var(--paper); border: 1px dashed var(--line); border-radius: var(--radius); display: grid; gap: 16px; justify-items: center; }
.empty-shop p { font-family: var(--serif); font-size: 22px; margin: 0; }
.desc p { margin: 0 0 12px; }
.legal { max-width: 760px; }
.legal-h1 { font-family: var(--serif); font-weight: 600; font-size: clamp(30px, 6vw, 42px); line-height: 1.1; margin: 0 0 24px; }
.legal .h3 { margin: 28px 0 8px; font-size: 22px; }
.legal p { color: var(--ink); }
.notfound { text-align: center; max-width: 640px; }
.site-footer .foot-bottom a { color: #fff; }

/* Appli de gestion (version réelle) */
body.admin #app { flex: 1; min-height: 0; display: flex; }
.app-page { flex: 1; min-height: 0; display: flex; justify-content: center; align-items: stretch; }
.app-frame { width: 100%; height: 100%; background: var(--cream); display: flex; flex-direction: column; position: relative; overflow: hidden; }
@media (min-width: 760px) {
  .app-page { align-items: center; padding: 24px 16px; background: var(--sand); }
  .app-frame { width: 480px; height: min(900px, 100%); border-radius: 24px; border: 1px solid var(--line); box-shadow: var(--shadow); flex: none; }
}
.banner-expired { background: #FFF3D6; color: #6B4E12; border: 1px solid #F0D58E; border-radius: 12px; padding: 10px 12px; font-size: 14px; text-align: left; }
.login .err-box, .err-box { background: #FBE4E1; color: var(--red-deep); border-radius: 12px; padding: 10px 12px; font-size: 14px; text-align: left; }
.ph.uploading { display: grid; place-items: center; }
.ph.uploading::after { content: ''; width: 26px; height: 26px; border-radius: 50%; border: 3px solid rgba(255,255,255,.6); border-top-color: var(--olive); animation: spin .8s linear infinite; position: absolute; }
.ph.uploading img { opacity: .55; }
.ph.failed { outline: 2px solid var(--red); }
.ph .retry { position: absolute; inset: auto 6px 6px 6px; border: 0; border-radius: 8px; background: var(--red-deep); color: #fff; font-size: 12px; font-weight: 700; padding: 5px; cursor: pointer; }
@keyframes spin { to { transform: rotate(360deg); } }
.pitem.trash img { filter: grayscale(.7); opacity: .8; }
.pitem .restore { grid-column: 1 / -1; }
.link-danger { background: none; border: 0; color: var(--red-deep); font-weight: 600; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; padding: 10px 0; }
.invite-box { background: var(--paper); border: 1px solid var(--line); border-radius: 14px; padding: 12px; font-size: 13px; word-break: break-all; margin: 8px 0; }
.admin-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; padding: 12px 14px; }
.admin-row + .admin-row { border-top: 1px solid var(--line); }
.small-btn { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; padding: 7px 10px; font-size: 13px; font-weight: 600; cursor: pointer; white-space: nowrap; }
.app-section-title { font-size: 13px; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); font-weight: 700; margin: 22px 0 8px; }
.view-site { display: inline-flex; gap: 6px; align-items: center; font-size: 14px; color: var(--olive); font-weight: 600; text-decoration: none; margin-top: 4px; }
.loading-screen { flex: 1; display: grid; place-items: center; color: var(--muted); }
.pitem .noimg { width: 56px; height: 68px; border-radius: 10px; background: var(--sand); display: block; }
.app-main .seg button { display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 12.5px; padding: 7px 2px; line-height: 1.2; }
.app-main .seg button .n { font-size: 12px; }
.settings .small-btn { width: auto; display: inline-block; flex: none; padding: 7px 10px; text-align: center; }
.app-main .btn { white-space: normal; text-align: center; }
.app-frame { max-width: 100vw; }
.admin-row > div { min-width: 0; }
.settings .small-btn { border: 1.5px solid var(--line); background: #fff; border-radius: 10px; }
details.more summary .muted { margin: 0 auto 0 6px; font-weight: 400; }
.site-footer .btn-route { margin-top: 8px; min-height: 40px; padding: 8px 16px; font-size: 14px; background: transparent; color: #fff; box-shadow: inset 0 0 0 1.5px rgba(255,255,255,.7); }
.site-footer .btn-route:hover { background: rgba(255,255,255,.1); }
.route-link { display: inline-flex; align-items: center; gap: 6px; margin-top: 8px; color: var(--olive); font-weight: 600; text-decoration: none; }
.route-link:hover { text-decoration: underline; text-underline-offset: 3px; }
.hp-row { justify-content: flex-start; }
.hp-thumb { width: 56px; height: 68px; border-radius: 10px; object-fit: cover; flex: none; background: var(--sand); }
.hp-meta { flex: 1; min-width: 0; }
.hp-actions { display: grid; gap: 6px; flex: none; }
.hp-row.busy { opacity: .6; pointer-events: none; }
.add-person { display: grid; gap: 8px; margin: 10px 0 4px; }
.add-person input { width: 100%; border: 1.5px solid var(--line); border-radius: 12px; background: #fff; padding: 12px 14px; font: inherit; font-size: 16px; color: var(--ink); }
.add-person input:focus { outline: none; border-color: var(--olive); box-shadow: 0 0 0 3px rgba(87,100,68,.15); }
/* Un élément marqué « hidden » reste caché même si sa classe impose un affichage (vignettes filtrées de la boutique). */
[hidden] { display: none !important; }
