/* Bijoux Maroc Pro — design system partagé */
:root {
  --ink: #1b1a17;
  --ink-2: #4a463e;
  --muted: #8a8476;
  --line: #e8e2d6;
  --line-2: #f1ece2;
  --bg: #faf7f1;
  --card: #ffffff;
  --gold: #b8892b;
  --gold-2: #d9b45a;
  --gold-soft: #f6ecd4;
  --emerald: #0f4d3c;
  --emerald-2: #1d6b55;
  --emerald-soft: #e3efe9;
  --red: #b4432f;
  --red-soft: #f8e5e0;
  --blue: #2c5aa0;
  --blue-soft: #e4ecf8;
  --wa: #1fa855;
  --radius: 14px;
  --shadow: 0 1px 2px rgba(27, 26, 23, .05), 0 6px 24px rgba(27, 26, 23, .06);
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
}
* { box-sizing: border-box; }
html, body { margin: 0; }
body { font-family: var(--sans); color: var(--ink); background: var(--bg); font-size: 14px; line-height: 1.5; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4 { margin: 0; line-height: 1.2; }
.serif { font-family: var(--serif); font-weight: 600; letter-spacing: .01em; }

/* logo */
.logo { display: inline-flex; align-items: center; gap: 10px; text-decoration: none; }
.logo-mark { width: 34px; height: 34px; border-radius: 10px; background: linear-gradient(135deg, var(--gold-2), var(--gold) 60%, #8a6418); display: grid; place-items: center; color: #fff; font-family: var(--serif); font-weight: 700; font-size: 19px; box-shadow: inset 0 1px 0 rgba(255,255,255,.4); }
.logo-text { font-family: var(--serif); font-weight: 700; font-size: 21px; letter-spacing: .02em; }
.logo-text small { display: block; font-family: var(--sans); font-size: 10px; font-weight: 600; letter-spacing: .14em; text-transform: uppercase; color: var(--muted); margin-top: -2px; }

/* boutons */
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 10px 16px; border-radius: 10px; border: 1px solid var(--line); background: var(--card); cursor: pointer; font-weight: 600; font-size: 13.5px; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, transform .05s; }
.btn:hover { border-color: #d6cdbb; background: #fdfbf7; }
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--emerald); border-color: var(--emerald); color: #fff; }
.btn-primary:hover { background: var(--emerald-2); border-color: var(--emerald-2); }
.btn-gold { background: var(--gold); border-color: var(--gold); color: #fff; }
.btn-gold:hover { background: #a67a22; border-color: #a67a22; }
.btn-wa { background: var(--wa); border-color: var(--wa); color: #fff; }
.btn-wa:hover { background: #18914a; border-color: #18914a; }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--line-2); border-color: transparent; }
.btn-sm { padding: 6px 10px; font-size: 12.5px; border-radius: 8px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }

/* formulaires */
.field { display: flex; flex-direction: column; gap: 6px; }
.field > span { font-size: 12px; font-weight: 600; color: var(--ink-2); }
.input, select.input, textarea.input { width: 100%; padding: 10px 12px; border: 1px solid var(--line); border-radius: 10px; background: #fff; outline: none; transition: border-color .15s, box-shadow .15s; }
.input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(184, 137, 43, .15); }
textarea.input { resize: vertical; min-height: 80px; }

/* étiquettes */
.tag { display: inline-flex; align-items: center; gap: 4px; padding: 3px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; background: var(--line-2); color: var(--ink-2); white-space: nowrap; }
.tag-gold { background: var(--gold-soft); color: #7d5a14; }
.tag-green { background: var(--emerald-soft); color: var(--emerald); }
.tag-red { background: var(--red-soft); color: var(--red); }
.tag-blue { background: var(--blue-soft); color: var(--blue); }
.tag-dark { background: var(--ink); color: #fff; }

.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); }

/* modale */
.modal-backdrop { position: fixed; inset: 0; background: rgba(20, 18, 14, .5); backdrop-filter: blur(3px); display: none; align-items: center; justify-content: center; z-index: 100; padding: 16px; }
.modal-backdrop.open { display: flex; animation: fade .15s ease-out; }
.modal { background: var(--card); border-radius: 18px; width: 100%; max-width: 860px; max-height: calc(100vh - 32px); overflow: auto; box-shadow: 0 30px 80px rgba(0,0,0,.25); position: relative; animation: pop .18s ease-out; }
.modal-sm { max-width: 520px; }
.modal-close { position: absolute; top: 12px; right: 12px; width: 34px; height: 34px; border-radius: 50%; border: none; background: rgba(255,255,255,.9); cursor: pointer; font-size: 18px; z-index: 2; box-shadow: 0 1px 4px rgba(0,0,0,.12); }
.modal-head { padding: 22px 24px 0; }
.modal-body { padding: 20px 24px 24px; }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: translateY(8px) scale(.98); opacity: 0; } }

/* toast */
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 30px); background: var(--ink); color: #fff; padding: 12px 18px; border-radius: 12px; font-weight: 500; box-shadow: 0 10px 30px rgba(0,0,0,.25); opacity: 0; pointer-events: none; transition: all .25s; z-index: 200; max-width: calc(100vw - 32px); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

/* bandeau démo */
.demo-bar { background: var(--ink); color: #e9e2d0; font-size: 12px; padding: 7px 16px; display: flex; gap: 14px; align-items: center; justify-content: center; flex-wrap: wrap; }
.demo-bar a { color: var(--gold-2); font-weight: 600; text-decoration: none; }
.demo-bar a:hover { text-decoration: underline; }
.demo-bar button { background: none; border: 1px solid #4b463d; color: #e9e2d0; border-radius: 6px; padding: 2px 8px; font-size: 11.5px; cursor: pointer; }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
@media (max-width: 640px) { .grid-2 { grid-template-columns: 1fr; } }
.muted { color: var(--muted); }
.row { display: flex; align-items: center; gap: 10px; }
.between { justify-content: space-between; }
.wrap { flex-wrap: wrap; }
.stars { color: var(--gold); letter-spacing: 1px; }
.empty { padding: 40px 16px; text-align: center; color: var(--muted); }
