/* ============================================================
   Atelier du Temps — feuille de style partagée
   Palette, typographie et composants validés (moodboard v5).
   Modifie les couleurs ici : ça se répercute sur toutes les pages.
   ============================================================ */

:root {
  --kraft: #D8D3BD;
  --surface: #EFEAD9;
  --surface-2: #E4DEC7;
  --ink: #2A2420;
  --ink-soft: #5C5347;
  --line: #C6BF9E;
  --brass: #9C7530;
  --brass-ink: #6E5321;
  --patine: #3F5C4E;
  --patine-bg: #DEE6DE;
  --good: #4C7A3F;
  --good-bg: #E2ECDD;
  --danger: #9C4A3A;
  --danger-bg: #F1E1DC;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --kraft: #201C16;
    --surface: #2A251E;
    --surface-2: #332C22;
    --ink: #EDE6D6;
    --ink-soft: #B4A98F;
    --line: #453D30;
    --brass: #D0A059;
    --brass-ink: #F0C687;
    --patine: #82A692;
    --patine-bg: #26332C;
    --good: #8FBF80;
    --good-bg: #263329;
    --danger: #D08A78;
    --danger-bg: #332420;
    color-scheme: dark;
  }
}
:root[data-theme="dark"] {
  --kraft: #201C16;
  --surface: #2A251E;
  --surface-2: #332C22;
  --ink: #EDE6D6;
  --ink-soft: #B4A98F;
  --line: #453D30;
  --brass: #D0A059;
  --brass-ink: #F0C687;
  --patine: #82A692;
  --patine-bg: #26332C;
  --good: #8FBF80;
  --good-bg: #263329;
  --danger: #D08A78;
  --danger-bg: #332420;
  color-scheme: dark;
}

* { box-sizing: border-box; }

html, body { margin: 0; }

body {
  background: var(--kraft);
  color: var(--ink);
  font-family: 'Source Serif 4', Georgia, 'Times New Roman', serif;
  padding-inline: max(18px, env(safe-area-inset-left, 0px));
  padding-block: 0 4rem;
}

a { color: var(--brass-ink); }

.wrap { width: 100%; max-width: 900px; margin: 0 auto; display: flex; flex-direction: column; gap: 2.75rem; }

h1, h2, h3 {
  font-family: 'Big Shoulders Display', 'Oswald', 'Arial Narrow', sans-serif;
  font-weight: 800;
  text-wrap: balance;
  margin: 0;
  line-height: 0.98;
}

/* ---------- Top bar ---------- */
.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1.1rem 0;
  margin-bottom: 0.5rem;
  border-bottom: 1px solid var(--line);
}
.topbar .brand {
  font-family: 'Big Shoulders Display', sans-serif;
  font-weight: 800;
  font-size: 1.75rem;
  text-decoration: none;
  color: var(--ink);
}
.topbar .brand span { color: var(--brass); }
.topbar nav { display: flex; gap: 1.2rem; font-family: 'IBM Plex Mono', monospace; font-size: 0.78rem; }
.topbar nav a { text-decoration: none; color: var(--ink-soft); }
.topbar nav a:hover { color: var(--brass-ink); }

.crumb {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-soft);
  display: flex;
  gap: 0.4rem;
  align-items: center;
  flex-wrap: wrap;
}
.crumb a { color: var(--ink-soft); text-decoration: none; }
.crumb a:hover { color: var(--brass-ink); }
.crumb b { color: var(--ink); font-weight: 600; }

.eyebrow {
  font-family: 'IBM Plex Mono', monospace;
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--brass-ink);
  display: flex;
  align-items: baseline;
  gap: 0.6rem;
}
.eyebrow::after { content: ""; flex: 1; height: 1px; background: var(--line); }

/* ---------- Product detail ---------- */
.product { display: grid; grid-template-columns: minmax(220px, 340px) 1fr; gap: 1.75rem; }
@media (max-width: 640px) { .product { grid-template-columns: 1fr; } }

.figure-panel {
  position: relative;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  padding: 1.4rem;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 260px;
  overflow: hidden;
}
.figure-panel::before {
  content: "";
  position: absolute;
  top: 1rem; left: 1.1rem;
  width: 0.75rem; height: 0.75rem;
  border-radius: 50%;
  background: var(--kraft);
  box-shadow: 0 0 0 2px var(--brass);
}
.figure-panel svg { width: 62%; max-width: 170px; height: auto; }
.figure-panel img { width: 100%; height: 100%; object-fit: cover; border-radius: 4px; }
.grade-badge {
  position: absolute; top: 1rem; right: 1rem;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.7rem; letter-spacing: 0.05em;
  padding: 0.3rem 0.6rem; border-radius: 20px;
  background: var(--good-bg); color: var(--good);
}

.info { display: flex; flex-direction: column; gap: 1rem; }
.cat-pill {
  align-self: flex-start;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.68rem; letter-spacing: 0.06em; text-transform: uppercase;
  padding: 0.25rem 0.55rem; border-radius: 20px;
  background: var(--patine-bg); color: var(--patine);
}
.info h1 { font-size: clamp(1.8rem, 5vw, 2.5rem); }
.story { color: var(--ink-soft); font-size: 1rem; line-height: 1.55; max-width: 48ch; }
.price-row { display: flex; align-items: baseline; gap: 0.6rem; }
.price { font-family: 'IBM Plex Mono', monospace; font-weight: 600; font-size: 2rem; color: var(--brass-ink); font-variant-numeric: tabular-nums; }
.price-note { font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; color: var(--ink-soft); }

.actions { display: flex; flex-direction: column; gap: 0.6rem; margin-top: 0.3rem; }
.btn {
  font-family: 'IBM Plex Mono', monospace; font-size: 0.85rem; letter-spacing: 0.02em;
  padding: 0.8rem 1.2rem; border-radius: 6px; border: 1px solid var(--brass);
  cursor: pointer; text-align: center; text-decoration: none; display: block;
}
.btn-primary { background: var(--brass); color: var(--surface); font-weight: 600; }
.btn-primary:hover { background: var(--brass-ink); border-color: var(--brass-ink); }
.btn-secondary { background: transparent; color: var(--brass-ink); }
.btn-secondary:hover { background: var(--patine-bg); }
.btn[disabled], .btn.is-disabled { opacity: 0.5; cursor: not-allowed; pointer-events: none; }
.btn:focus-visible { outline: 2px solid var(--patine); outline-offset: 2px; }
.actions-note { font-size: 0.82rem; color: var(--ink-soft); line-height: 1.4; }

.warranty {
  display: flex; align-items: center; gap: 0.5rem;
  font-size: 0.85rem; color: var(--ink-soft);
  border-top: 1px solid var(--line); padding-top: 0.8rem; margin-top: 0.2rem;
}
.warranty svg { width: 18px; height: 18px; flex-shrink: 0; color: var(--patine); }

/* ---------- Specs ---------- */
.specs { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 0.3rem 1.3rem; }
.spec-row { display: grid; grid-template-columns: 11rem 1fr; gap: 1rem; padding: 0.75rem 0; border-bottom: 1px solid var(--line); font-size: 0.92rem; }
.spec-row:last-child { border-bottom: none; }
.spec-label { font-family: 'IBM Plex Mono', monospace; font-size: 0.75rem; color: var(--ink-soft); letter-spacing: 0.02em; }
.spec-value { font-family: 'IBM Plex Mono', monospace; }
@media (max-width: 480px) { .spec-row { grid-template-columns: 1fr; gap: 0.15rem; } }

/* ---------- Pickup ---------- */
.pickup { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 1.2rem 1.3rem; display: flex; flex-direction: column; gap: 0.9rem; }
.pickup-row { display: flex; gap: 0.7rem; align-items: flex-start; }
.pickup-row svg { width: 20px; height: 20px; flex-shrink: 0; color: var(--brass-ink); margin-top: 0.15rem; }
.pickup-row div b { display: block; font-size: 0.9rem; }
.pickup-row div span { font-size: 0.85rem; color: var(--ink-soft); }
.pay-methods { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.pay-pill { font-family: 'IBM Plex Mono', monospace; font-size: 0.7rem; padding: 0.25rem 0.6rem; border-radius: 20px; border: 1px solid var(--line); color: var(--ink-soft); }

/* ---------- Catalogue grid (boutique index) ---------- */
.catalog-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 1.1rem; }
.catalog-card, .mini-card {
  position: relative; background: var(--surface); border: 1px solid var(--line); border-radius: 8px;
  padding: 1.1rem 1rem; display: flex; flex-direction: column; gap: 0.5rem;
  text-decoration: none; color: inherit;
}
.catalog-card:hover { border-color: var(--brass); }
.catalog-card::before, .mini-card::before {
  content: ""; position: absolute; top: 0.7rem; left: 1rem; width: 0.6rem; height: 0.6rem;
  border-radius: 50%; background: var(--kraft); box-shadow: 0 0 0 2px var(--brass);
}
.card-thumb, .mini-thumb { height: 84px; border-radius: 6px; background: var(--surface-2); display: flex; align-items: center; justify-content: center; color: var(--ink-soft); overflow: hidden; }
.card-thumb svg, .mini-thumb svg { width: 36px; height: 36px; }
.card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.card-title, .mini-title { font-family: 'Big Shoulders Display', sans-serif; font-weight: 700; font-size: 1.15rem; line-height: 1.05; }
.card-meta { display: flex; align-items: center; justify-content: space-between; margin-top: auto; }
.mini-price, .card-price { font-family: 'IBM Plex Mono', monospace; font-size: 0.85rem; color: var(--brass-ink); font-weight: 600; }

.empty-state { color: var(--ink-soft); font-size: 0.95rem; padding: 2rem 0; text-align: center; border: 1px dashed var(--line); border-radius: 8px; }

/* ---------- Form (reservation) ---------- */
.form-panel { background: var(--surface); border: 1px solid var(--line); border-radius: 8px; padding: 1.4rem clamp(1rem, 4vw, 1.8rem); display: flex; flex-direction: column; gap: 1rem; }
.field { display: flex; flex-direction: column; gap: 0.35rem; }
.field label { font-family: 'IBM Plex Mono', monospace; font-size: 0.72rem; letter-spacing: 0.04em; text-transform: uppercase; color: var(--ink-soft); }
.field input, .field textarea {
  font-family: 'Source Serif 4', Georgia, serif; font-size: 0.95rem;
  padding: 0.6rem 0.7rem; border: 1px solid var(--line); border-radius: 6px;
  background: var(--kraft); color: var(--ink);
}
.field input:focus, .field textarea:focus { outline: 2px solid var(--patine); outline-offset: 1px; }
.field textarea { resize: vertical; min-height: 5rem; }

/* ---------- Notices ---------- */
.notice { border-radius: 8px; padding: 1.1rem 1.3rem; font-size: 0.95rem; line-height: 1.5; }
.notice-ok { background: var(--good-bg); color: var(--good); }
.notice-error { background: var(--danger-bg); color: var(--danger); }
.notice code { font-family: 'IBM Plex Mono', monospace; font-size: 0.85em; }

/* ---------- Homepage: hero ---------- */
.hero-home { display: flex; flex-direction: column; gap: 1.6rem; padding-block: 1.5rem 0.5rem; }
.hero-home h1 { font-size: clamp(2.4rem, 7vw, 4rem); }
.hero-home h1 span { color: var(--brass); }
.hero-tagline { font-size: 1.15rem; font-style: italic; color: var(--ink-soft); max-width: 40ch; margin: 0.7rem 0 1.1rem; }
.hero-cta { display: flex; gap: 0.8rem; flex-wrap: wrap; }
.hero-cta .btn { display: inline-block; width: auto; }


/* Full-width avant/après banner, shown before the title */
.hero-banner {
  width: 100%; background: var(--surface); border: 1px solid var(--line); border-radius: 10px;
  padding: 2rem clamp(1rem, 5vw, 3rem);
  display: flex; align-items: center; justify-content: center; gap: clamp(1rem, 6vw, 4rem); flex-wrap: wrap;
}
.hero-banner figure { margin: 0; display: flex; flex-direction: column; align-items: center; gap: 0.6rem; }
.hero-banner svg { width: clamp(110px, 16vw, 200px); height: auto; }
.hero-label { font-family: 'IBM Plex Mono', monospace; font-size: 0.75rem; letter-spacing: 0.12em; text-transform: uppercase; }
.hero-label.before { color: var(--ink-soft); }
.hero-label.after { color: var(--brass-ink); }
.hero-arrow { font-family: 'Big Shoulders Display', sans-serif; font-size: 2.4rem; color: var(--ink-soft); }

/* ---------- Homepage: nav anchors as full site nav ---------- */
.topbar nav a.current { color: var(--brass-ink); }

/* ---------- Section heading with intro text ---------- */
.section-intro { color: var(--ink-soft); font-size: 1rem; max-width: 60ch; line-height: 1.55; text-align: justify; hyphens: auto; }
.section-intro.wide { max-width: none; }

/* ---------- CTA banner (quiet secondary color, used once) ---------- */
.cta-banner {
  background: var(--patine-bg); border-radius: 10px; padding: 1.6rem clamp(1.1rem, 4vw, 2rem);
  display: flex; align-items: center; justify-content: space-between; gap: 1rem; flex-wrap: wrap;
}
.cta-banner h3 { color: var(--patine); font-size: 1.4rem; }
.cta-banner p { margin: 0.3rem 0 0; color: var(--ink-soft); font-size: 0.92rem; }
.cta-banner .btn { flex-shrink: 0; }

/* ---------- Realisation teaser cards (pulled from the live catalogue) ---------- */
.realisation-card { display: flex; flex-direction: column; gap: 0.5rem; }
.realisation-card .story { font-size: 0.88rem; }

/* ---------- Devis form ---------- */
.field select {
  font-family: 'Source Serif 4', Georgia, serif; font-size: 0.95rem;
  padding: 0.6rem 0.7rem; border: 1px solid var(--line); border-radius: 6px;
  background: var(--kraft); color: var(--ink);
}
.field select:focus { outline: 2px solid var(--patine); outline-offset: 1px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }

footer.site-footer {
  border-top: 1px solid var(--line); padding-top: 1.1rem; margin-top: 1rem;
  font-family: 'IBM Plex Mono', monospace; font-size: 0.68rem; color: var(--ink-soft); letter-spacing: 0.04em;
}
