/* Bijouterie — MVP : design system */
:root {
  --ink: #1b1a17; --ink-2: #4a463e; --muted: #857f71; --line: #e8e2d6; --line-2: #f1ece2;
  --bg: #faf7f1; --card: #fff;
  --gold: #b8892b; --gold-2: #d9b45a; --gold-soft: #f6ecd4;
  --emerald: #0f4d3c; --emerald-2: #1d6b55; --emerald-soft: #e3efe9;
  --red: #b4432f; --red-soft: #f8e5e0; --wa: #1fa855; --wa-dark: #128c45;
  --radius: 16px;
  --shadow: 0 1px 2px rgba(27,26,23,.05), 0 10px 30px rgba(27,26,23,.07);
  --serif: 'Cormorant Garamond', Georgia, serif;
  --sans: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
* { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
html, body { margin: 0; }
body { font-family: var(--sans); color: var(--ink); background: var(--bg); font-size: 15px; line-height: 1.55; -webkit-font-smoothing: antialiased; }
a { color: inherit; }
img { max-width: 100%; }
button, input, select, textarea { font: inherit; color: inherit; }
h1, h2, h3, h4, p { margin: 0; }
:focus-visible { outline: 2px solid var(--gold); outline-offset: 2px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; padding: 11px 18px; border-radius: 12px; border: 1px solid var(--line); background: var(--card); cursor: pointer; font-weight: 600; font-size: 14px; text-decoration: none; white-space: nowrap; transition: background .15s, border-color .15s, transform .06s, box-shadow .15s; }
.btn:hover { border-color: #d3c9b5; }
.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: var(--wa-dark); border-color: var(--wa-dark); }
.btn-ghost { background: transparent; border-color: transparent; }
.btn-ghost:hover { background: var(--line-2); }
.btn-danger { color: var(--red); }
.btn-danger:hover { background: var(--red-soft); border-color: #eccbc2; }
.btn-sm { padding: 7px 12px; font-size: 13px; border-radius: 9px; }
.btn-lg { padding: 14px 22px; font-size: 15px; border-radius: 14px; }
.btn-block { width: 100%; }
.btn:disabled { opacity: .5; cursor: not-allowed; }
.btn svg { flex: none; }

.field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.field > span { font-size: 12.5px; font-weight: 600; color: var(--ink-2); }
.field small { color: var(--muted); font-size: 12px; }
.input { width: 100%; padding: 11px 13px; border: 1px solid var(--line); border-radius: 11px; background: #fff; outline: none; transition: border-color .15s, box-shadow .15s; min-width: 0; }
.input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(184,137,43,.15); }
textarea.input { resize: vertical; min-height: 90px; }
select.input { appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23857f71' stroke-width='2.5'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 12px center; padding-right: 34px; }

.tag { display: inline-flex; align-items: center; gap: 5px; padding: 3px 9px; border-radius: 999px; font-size: 11.5px; font-weight: 700; 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-dark { background: var(--ink); color: #fff; }
.dot { width: 8px; height: 8px; border-radius: 50%; display: inline-block; background: currentColor; }

.logo { display: inline-flex; align-items: center; gap: 11px; text-decoration: none; min-width: 0; }
.logo-mark { width: 40px; height: 40px; border-radius: 12px; 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: 22px; flex: none; box-shadow: inset 0 1px 0 rgba(255,255,255,.35); }
.logo-text { font-family: var(--serif); font-weight: 700; font-size: 22px; line-height: 1.05; min-width: 0; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.logo-text small { display: block; font-family: var(--sans); font-size: 10.5px; font-weight: 600; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-top: 3px; overflow: hidden; text-overflow: ellipsis; }

.modal-backdrop { position: fixed; inset: 0; background: rgba(20,18,14,.55); backdrop-filter: blur(4px); 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: 22px; width: 100%; max-width: 940px; max-height: calc(100vh - 32px); max-height: calc(100dvh - 32px); overflow: auto; overscroll-behavior: contain; box-shadow: 0 30px 80px rgba(0,0,0,.28); position: relative; animation: pop .2s ease-out; }
.modal-close { position: sticky; top: 12px; display: block; margin: 12px 12px -50px auto; width: 38px; height: 38px; border-radius: 50%; border: none; background: rgba(255,255,255,.95); cursor: pointer; font-size: 22px; line-height: 1; z-index: 3; box-shadow: 0 2px 8px rgba(0,0,0,.15); }
@keyframes fade { from { opacity: 0; } }
@keyframes pop { from { transform: translateY(10px) scale(.985); opacity: 0; } }

.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; font-size: 14px; box-shadow: 0 10px 30px rgba(0,0,0,.25); opacity: 0; pointer-events: none; transition: all .25s; z-index: 300; max-width: calc(100vw - 32px); text-align: center; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.muted { color: var(--muted); }
.row { display: flex; align-items: center; gap: 10px; }
.wrap { flex-wrap: wrap; }
.between { justify-content: space-between; }
.empty { padding: 48px 16px; text-align: center; color: var(--muted); background: #fff; border: 1px dashed var(--line); border-radius: var(--radius); }

@media (max-width: 640px) {
  .modal-backdrop { padding: 0; align-items: flex-end; }
  .modal { border-radius: 22px 22px 0 0; max-height: 94vh; max-height: 94dvh; }
  .toast { bottom: 84px; }
}
