/* ============================================================
   Espace Agent · MonRiad — Stylesheet
   Palette inspirée du site mon-riad.ma (or chaud + crème)
   ============================================================ */

:root {
  --bg:        #f7f3ec;
  --surface:   #ffffff;
  --surface-2: #fbf8f2;
  --border:    #e5dcc9;
  --text:      #2a2418;
  --text-dk:   #46402f;
  --muted:     #8b8270;
  --gold:      #b8954a;
  --gold-dk:   #94772f;
  --gold-soft: #f3e9d3;
  --green:     #2f8a4d;
  --red:       #c0392b;
  --orange:    #d97a18;
  --shadow:    0 4px 16px rgba(46, 36, 16, 0.08);
  --shadow-lg: 0 12px 36px rgba(46, 36, 16, 0.14);
  --radius:    12px;
  --radius-sm: 8px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", sans-serif;
  font-size: 14.5px;
  line-height: 1.5;
}
a { color: var(--gold-dk); text-decoration: none; }
a:hover { text-decoration: underline; }
img { max-width: 100%; height: auto; display: block; }
.muted { color: var(--muted); }
.small { font-size: .82em; }
.req { color: var(--red); }

/* ════════ LOGIN ════════ */
.login-body {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at 20% 10%, var(--gold-soft) 0%, transparent 50%),
    radial-gradient(circle at 80% 90%, var(--gold-soft) 0%, transparent 50%),
    var(--bg);
}
.login-wrap { width: 100%; max-width: 420px; padding: 24px; }
.login-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 36px 32px;
  box-shadow: var(--shadow-lg);
}
.login-brand { text-align: center; margin-bottom: 24px; }
.brand-mark {
  display: inline-grid; place-items: center;
  width: 52px; height: 52px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--gold), var(--gold-dk));
  color: #fff; font-weight: 700; font-size: 1.5rem;
  margin-bottom: 12px;
  box-shadow: 0 6px 16px rgba(184, 149, 74, 0.35);
}
.login-brand h1 { margin: 0; font-size: 1.4rem; }
.login-brand p { margin: 4px 0 0; color: var(--muted); font-size: .88rem; }
.login-foot { text-align: center; color: var(--muted); font-size: .8rem; margin-top: 18px; }

/* Forms */
form label { display: block; margin-bottom: 14px; font-size: .85rem; color: var(--text-dk); font-weight: 500; }
form input[type=text], form input[type=password], form input[type=email], form input[type=number],
form input[type=tel], form input[type=url], form select, form textarea {
  display: block; width: 100%;
  margin-top: 4px;
  padding: 10px 12px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface);
  color: var(--text);
  font-size: .9rem;
  font-family: inherit;
}
form input:focus, form select:focus, form textarea:focus {
  outline: none;
  border-color: var(--gold);
  box-shadow: 0 0 0 3px var(--gold-soft);
}
form input[disabled] { background: var(--surface-2); color: var(--muted); }
form textarea { resize: vertical; min-height: 80px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }

/* Buttons */
.btn {
  display: inline-block;
  padding: 10px 18px;
  border-radius: var(--radius-sm);
  font-size: .88rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1px solid transparent;
  transition: all .15s;
  text-decoration: none;
  text-align: center;
}
.btn-primary { background: var(--gold); color: #fff; border-color: var(--gold); }
.btn-primary:hover { background: var(--gold-dk); border-color: var(--gold-dk); text-decoration: none; }
.btn-ghost { background: var(--surface); color: var(--text-dk); border: 1px solid var(--border); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-danger { background: var(--red); color: #fff; border-color: var(--red); }
.btn-danger:hover { filter: brightness(.92); }
.btn-block { width: 100%; }
.btn-lg { padding: 13px 24px; font-size: .95rem; }
.btn-text { background: none; border: none; color: var(--text-dk); cursor: pointer; padding: 8px 12px; font-family: inherit; font-size: .85rem; }
.btn-text:hover { color: var(--gold-dk); }
.btn-text-back { color: var(--muted); font-size: .82rem; }
.btn-link { background: none; border: none; color: var(--gold-dk); cursor: pointer; padding: 0; font-family: inherit; font-size: .88rem; text-decoration: underline; }
.btn-link-danger { background: none; border: none; color: var(--red); cursor: pointer; padding: 0 0 0 8px; font-family: inherit; font-size: .82rem; text-decoration: underline; }

/* Alerts / toasts */
.alert, .toast {
  padding: 10px 14px;
  border-radius: var(--radius-sm);
  margin-bottom: 14px;
  font-size: .88rem;
}
.alert-err, .toast-err { background: #fdecea; color: #8b2e23; border: 1px solid #f3c1bb; }
.toast-ok { background: #e9f5ec; color: #1f5e30; border: 1px solid #b9dfc3; }

/* ════════ TOPBAR ════════ */
.topbar {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  padding: 12px 0;
  position: sticky; top: 0; z-index: 50;
  box-shadow: 0 2px 8px rgba(46, 36, 16, 0.04);
}
.topbar-inner {
  max-width: 1280px; margin: 0 auto;
  padding: 0 24px;
  display: flex; align-items: center; gap: 24px;
  flex-wrap: wrap;
}
.brand { display: inline-flex; align-items: center; gap: 10px; color: var(--text); font-weight: 700; text-decoration: none; }
.brand .brand-mark { width: 36px; height: 36px; font-size: 1rem; margin: 0; box-shadow: none; }
.brand-text { font-size: 1.02rem; }
.topnav { display: flex; gap: 4px; flex: 1; flex-wrap: wrap; }
.topnav a {
  padding: 8px 14px;
  border-radius: var(--radius-sm);
  color: var(--text-dk);
  font-size: .9rem;
  font-weight: 500;
}
.topnav a:hover { background: var(--surface-2); text-decoration: none; }
.topnav a.active { background: var(--gold-soft); color: var(--gold-dk); }
.topbar-user { display: flex; align-items: center; gap: 12px; }
.user-chip { background: var(--surface-2); padding: 6px 12px; border-radius: 999px; font-size: .85rem; }
.badge-admin {
  background: var(--gold); color: #fff;
  padding: 1px 7px; border-radius: 999px;
  font-size: .68rem; margin-left: 6px; text-transform: uppercase;
  font-weight: 700; letter-spacing: .3px;
}

/* ════════ PAGE ════════ */
.page { max-width: 1280px; margin: 0 auto; padding: 28px 24px 60px; }
.page-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  gap: 20px; flex-wrap: wrap; margin-bottom: 24px;
}
.page-head h1 { margin: 0; font-size: 1.6rem; }
.page-head .muted { margin: 4px 0 0; font-size: .88rem; }
.page-head-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ════════ FILTERS ════════ */
.filters {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  margin-bottom: 22px;
  box-shadow: var(--shadow);
}
.filter-tabs { display: flex; gap: 4px; margin-bottom: 14px; border-bottom: 1px solid var(--border); }
.filter-tabs .tab {
  padding: 8px 16px;
  font-size: .9rem;
  color: var(--muted);
  border-bottom: 2px solid transparent;
  font-weight: 500;
}
.filter-tabs .tab:hover { color: var(--text); text-decoration: none; }
.filter-tabs .tab.active { color: var(--gold-dk); border-bottom-color: var(--gold); }
.filter-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 10px;
}
.filter-actions { display: flex; gap: 8px; margin-top: 12px; }

/* ════════ CARDS GRID ════════ */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 20px;
}
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex; flex-direction: column;
  color: var(--text);
  text-decoration: none !important;
  box-shadow: var(--shadow);
  transition: transform .15s, box-shadow .15s;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lg); }
.card-thumb {
  position: relative;
  aspect-ratio: 4 / 3;
  background: var(--surface-2);
  overflow: hidden;
}
.card-thumb img { width: 100%; height: 100%; object-fit: cover; }
.thumb-placeholder {
  width: 100%; height: 100%;
  display: grid; place-items: center;
  font-size: 2.5rem; color: var(--border);
}
.status-dot {
  position: absolute; top: 10px; right: 10px;
  padding: 3px 10px; border-radius: 999px;
  font-size: .68rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .3px; color: #fff;
  box-shadow: 0 2px 6px rgba(0,0,0,.18);
}
.status-disponible { background: var(--green); }
.status-vendu      { background: var(--red); }
.status-complique  { background: var(--orange); }
.badge-draft {
  position: absolute; top: 10px; left: 10px;
  padding: 3px 10px; border-radius: 999px;
  background: #fff; color: var(--text-dk);
  font-size: .68rem; font-weight: 700; text-transform: uppercase;
  border: 1px dashed var(--border);
}
.card-body { padding: 14px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.card-body h3 { margin: 0; font-size: 1rem; }
.card-meta { display: flex; gap: 14px; flex-wrap: wrap; margin: 0; font-size: .82rem; color: var(--muted); }
.card-price { margin: 0; font-size: 1.05rem; font-weight: 700; color: var(--gold-dk); }
.card-progress { display: flex; align-items: center; gap: 8px; }
.progress-bar {
  flex: 1; height: 6px; background: var(--surface-2);
  border-radius: 999px; overflow: hidden; border: 1px solid var(--border);
}
.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--gold), var(--gold-dk));
  transition: width .3s;
}
.progress-label { font-size: .72rem; color: var(--muted); font-weight: 600; min-width: 32px; text-align: right; }
.card-foot {
  display: flex; justify-content: space-between; align-items: center;
  margin-top: auto; padding-top: 8px;
  border-top: 1px solid var(--border);
  font-size: .76rem;
}
.badge-ok {
  background: #e9f5ec; color: #1f5e30;
  padding: 2px 8px; border-radius: 999px;
  font-size: .72rem; font-weight: 600; border: 1px solid #b9dfc3;
}

/* ════════ EMPTY ════════ */
.empty {
  background: var(--surface); border: 1px dashed var(--border);
  border-radius: var(--radius); padding: 60px 20px;
  text-align: center; color: var(--muted);
}
.empty p { margin: 0 0 16px; }

/* ════════ FORM CARD ════════ */
.form-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  margin-bottom: 20px;
  box-shadow: var(--shadow);
  max-width: 900px;
}
.form-card h2 { margin: 0 0 16px; font-size: 1.15rem; }
.form-property fieldset {
  border: none;
  padding: 0 0 20px;
  margin: 0 0 20px;
  border-bottom: 1px solid var(--border);
}
.form-property fieldset:last-of-type { border-bottom: none; }
.form-property legend {
  font-weight: 700; font-size: 1.02rem; color: var(--text);
  margin-bottom: 14px; padding: 0;
}
.yesno-block {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 14px;
  margin-bottom: 14px;
}
.yesno-block > p { margin: 0 0 10px; font-weight: 500; color: var(--text-dk); font-size: .9rem; }
.radio-row { display: flex; gap: 16px; margin-bottom: 10px; }
.radio-row label { margin: 0; display: inline-flex; align-items: center; gap: 6px; font-weight: normal; }
.radio-row input { margin: 0; }
.conditional { margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--border); display: none; }
.conditional.show { display: block; }
.check-block {
  display: flex !important; align-items: center; gap: 8px;
  margin: 0 !important; font-weight: normal !important;
}
.check-block input { width: auto !important; margin: 0 !important; }
.form-actions {
  display: flex; gap: 10px; justify-content: flex-end;
  padding-top: 8px; flex-wrap: wrap;
}
.existing-file {
  background: #fff; border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 8px 12px;
  margin-bottom: 8px; font-size: .85rem;
  display: flex; align-items: center; justify-content: space-between; gap: 8px;
}
.file-list { display: flex; flex-direction: column; gap: 4px; margin-bottom: 8px; }
.thumb-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(110px, 1fr)); gap: 8px; margin-bottom: 10px; }
.thumb-item { position: relative; aspect-ratio: 1; border-radius: var(--radius-sm); overflow: hidden; border: 1px solid var(--border); }
.thumb-item img { width: 100%; height: 100%; object-fit: cover; }
.thumb-del {
  position: absolute; top: 4px; right: 4px;
  background: rgba(0,0,0,.65); color: #fff;
  border: none; border-radius: 50%; width: 24px; height: 24px;
  cursor: pointer; font-size: .9rem;
}
.video-block { margin-top: 12px; }

/* ════════ DETAIL ════════ */
.detail-progress {
  display: flex; align-items: center; gap: 12px;
  margin-bottom: 18px;
  background: var(--surface); padding: 12px 16px;
  border: 1px solid var(--border); border-radius: var(--radius);
}
.detail-quick-actions {
  display: flex; gap: 12px; flex-wrap: wrap;
  margin-bottom: 22px;
}
.inline-form { display: inline-flex; align-items: center; gap: 8px; margin: 0; }
.inline-form label { display: inline-flex; align-items: center; gap: 6px; margin: 0; }
.inline-form select { margin: 0; }
.detail-section {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px;
  margin-bottom: 18px;
  box-shadow: var(--shadow);
}
.detail-section h2 { margin: 0 0 14px; font-size: 1.1rem; color: var(--text); }
.detail-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
.kv {
  background: var(--surface-2); padding: 10px 14px;
  border-radius: var(--radius-sm); border: 1px solid var(--border);
}
.kv span { display: block; font-size: .76rem; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; margin-bottom: 4px; }
.kv strong { font-size: .95rem; color: var(--text); font-weight: 600; }
.kv-block { background: var(--surface-2); padding: 12px; border-radius: var(--radius-sm); border: 1px solid var(--border); margin-top: 12px; }
.kv-block span { display: block; font-size: .76rem; color: var(--muted); text-transform: uppercase; margin-bottom: 6px; }
.kv-block p { margin: 0; }
.gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
}
.gal-main { grid-column: 1 / -1; aspect-ratio: 16 / 9; max-height: 480px; }
.gal-main img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.gal-thumb { aspect-ratio: 1; }
.gal-thumb img { width: 100%; height: 100%; object-fit: cover; border-radius: var(--radius-sm); border: 1px solid var(--border); }
.video-link-box {
  display: inline-block;
  padding: 12px 18px;
  background: linear-gradient(135deg, var(--gold), var(--gold-dk));
  color: #fff !important;
  border-radius: var(--radius-sm);
  font-weight: 600;
}
.video-link-box:hover { text-decoration: none; filter: brightness(1.05); }
.docs-list { display: flex; flex-direction: column; gap: 6px; }
.doc-item {
  display: inline-block;
  background: var(--surface-2);
  padding: 8px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: .9rem;
}
.doc-item:hover { background: var(--gold-soft); text-decoration: none; }
.owner-list { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 10px; }
.owner-card {
  display: flex; gap: 12px; align-items: center;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm); padding: 12px;
}
.owner-num {
  width: 28px; height: 28px; border-radius: 50%;
  background: var(--gold); color: #fff;
  display: grid; place-items: center; font-weight: 700;
}
.owner-name { font-weight: 600; }
.owner-tel { color: var(--muted); font-size: .85rem; }
.long-text { margin: 0; white-space: pre-wrap; }
.status-pill {
  display: inline-block;
  padding: 2px 10px; border-radius: 999px;
  font-size: .7rem; font-weight: 700; text-transform: uppercase;
  letter-spacing: .3px; color: #fff;
  vertical-align: middle; margin-left: 8px;
}
.badge-draft-inline {
  background: var(--surface-2); color: var(--text-dk);
  border: 1px dashed var(--border);
  padding: 2px 10px; border-radius: 999px;
  font-size: .72rem; font-weight: 600;
}

/* ════════ AGENTS TABLE ════════ */
.agents-table {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
}
.agents-table table { width: 100%; border-collapse: collapse; font-size: .88rem; }
.agents-table th, .agents-table td {
  padding: 12px 16px;
  text-align: left;
  border-bottom: 1px solid var(--border);
}
.agents-table th {
  background: var(--surface-2);
  font-weight: 600; font-size: .78rem;
  text-transform: uppercase; letter-spacing: .3px;
  color: var(--muted);
}
.agents-table tr:last-child td { border-bottom: none; }
.row-disabled { opacity: .55; }
.badge-on   { background: #e9f5ec; color: #1f5e30; padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 600; }
.badge-off  { background: #fdecea; color: #8b2e23; padding: 2px 8px; border-radius: 999px; font-size: .72rem; font-weight: 600; }

/* ════════ MODAL ════════ */
.modal {
  display: none;
  position: fixed; inset: 0;
  background: rgba(20, 14, 6, .55);
  z-index: 100;
  align-items: center; justify-content: center;
  padding: 20px;
}
.modal.show { display: flex; }
.modal-box {
  background: var(--surface);
  border-radius: var(--radius);
  padding: 28px;
  max-width: 540px; width: 100%;
  position: relative;
  box-shadow: var(--shadow-lg);
}
.modal-box h3 { margin: 0 0 14px; }
.modal-box ol { padding-left: 20px; margin: 0 0 14px; }
.modal-box li { margin-bottom: 8px; line-height: 1.55; }
.modal-close {
  position: absolute; top: 14px; right: 14px;
  background: none; border: none;
  font-size: 1.2rem; cursor: pointer; color: var(--muted);
}
.modal-close:hover { color: var(--text); }

/* ════════ RESPONSIVE ════════ */
@media (max-width: 768px) {
  .page { padding: 18px 14px 40px; }
  .form-row { grid-template-columns: 1fr; }
  .page-head { flex-direction: column; align-items: stretch; }
  .topbar-inner { gap: 12px; }
  .topnav { order: 3; width: 100%; justify-content: center; }
  .topbar-user { margin-left: auto; }
  .agents-table { overflow-x: auto; }
  .agents-table table { min-width: 700px; }
}

/* ════════════════════════════════════════════════════════
   V2 : Sélecteur langue, filtres simplifiés
   ════════════════════════════════════════════════════════ */
.lang-switch {
  display: inline-flex; align-items: center;
  padding: 6px 12px; border-radius: 999px;
  background: rgba(176, 141, 87, 0.1);
  color: var(--gold-dark);
  font-size: .88rem; font-weight: 500;
  text-decoration: none; transition: background .15s;
  margin-right: 10px;
}
.lang-switch:hover { background: rgba(176, 141, 87, 0.2); }
.login-lang-switch {
  position: fixed; top: 18px; right: 18px; z-index: 100;
}
.login-lang-switch a {
  display: inline-block; padding: 8px 14px;
  border-radius: 999px;
  background: rgba(255,255,255,0.85); color: var(--gold-dark);
  text-decoration: none; font-weight: 500;
  border: 1px solid rgba(176, 141, 87, 0.3);
  box-shadow: 0 2px 6px rgba(0,0,0,0.06);
}

.filter-grid-3 {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
}

/* ════════════════════════════════════════════════════════
   V2 : Carrousel photos
   ════════════════════════════════════════════════════════ */
.section-head {
  display: flex; justify-content: space-between; align-items: flex-end;
  flex-wrap: wrap; gap: 12px;
  margin-bottom: 14px;
}
.section-head h2 { margin: 0; }
.photo-actions {
  display: flex; gap: 8px; flex-wrap: wrap;
}

.btn-sm {
  padding: 7px 14px !important;
  font-size: .88rem !important;
}
.btn-pill {
  display: inline-block;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0,0,0,0.55);
  color: white;
  text-decoration: none;
  font-size: .85rem;
  font-weight: 500;
  border: 1px solid rgba(255,255,255,0.2);
  backdrop-filter: blur(6px);
}
.btn-pill:hover { background: rgba(0,0,0,0.7); }

.btn-wa {
  background: #25D366 !important;
  color: white !important;
  border-color: #25D366 !important;
}
.btn-wa:hover { background: #1da851 !important; border-color: #1da851 !important; }

.carousel {
  position: relative;
  background: #1a1a1a;
  border-radius: 14px;
  overflow: hidden;
  height: 65vh;
  max-height: 720px;
  min-height: 340px;
  user-select: none;
}
.carousel-track {
  display: flex;
  width: 100%; height: 100%;
  transition: transform .35s cubic-bezier(.4,.0,.2,1);
  touch-action: pan-y;
}
.carousel-slide {
  flex: 0 0 100%;
  height: 100%;
  display: flex; align-items: center; justify-content: center;
}
.carousel-slide img {
  width: 100%; height: 100%;
  object-fit: contain;
  display: block;
}
.carousel-arrow {
  position: absolute;
  top: 50%; transform: translateY(-50%);
  width: 44px; height: 44px;
  border-radius: 50%;
  background: rgba(0,0,0,0.55);
  color: white;
  border: 1px solid rgba(255,255,255,0.2);
  font-size: 1.8rem; line-height: 1;
  cursor: pointer; z-index: 2;
  display: flex; align-items: center; justify-content: center;
  backdrop-filter: blur(6px);
  transition: background .15s;
}
.carousel-arrow:hover { background: rgba(0,0,0,0.75); }
.carousel-prev { left: 12px; }
.carousel-next { right: 12px; }
.carousel-counter {
  position: absolute;
  top: 12px; left: 50%; transform: translateX(-50%);
  background: rgba(0,0,0,0.55);
  color: white;
  padding: 4px 12px;
  border-radius: 999px;
  font-size: .85rem;
  backdrop-filter: blur(6px);
}
.carousel-controls {
  position: absolute;
  bottom: 12px; right: 12px;
  display: flex; gap: 8px;
}
.carousel-dots {
  display: flex; justify-content: center; gap: 8px;
  margin-top: 14px;
  flex-wrap: wrap;
}
.dot {
  width: 10px; height: 10px;
  border-radius: 50%;
  background: rgba(0,0,0,0.18);
  border: none; cursor: pointer;
  padding: 0;
  transition: background .15s, transform .15s;
}
.dot.active {
  background: var(--gold);
  transform: scale(1.3);
}
.dot:hover { background: rgba(0,0,0,0.4); }

@media (max-width: 600px) {
  .carousel { height: 55vh; min-height: 260px; }
  .carousel-arrow { width: 38px; height: 38px; font-size: 1.5rem; }
  .carousel-prev { left: 6px; } .carousel-next { right: 6px; }
}

/* Fallback : si JS désactivé, montrer seulement la 1re photo + cacher contrôles */
.no-js .carousel-track { display: block !important; }
.no-js .carousel-slide { display: none !important; }
.no-js .carousel-slide:first-child { display: flex !important; }
.no-js .carousel-arrow, .no-js .carousel-controls, .no-js .carousel-counter, .no-js .carousel-dots { display: none !important; }

/* ════════════════════════════════════════════════════════
   V2 : Action IA (bouton + statut)
   ════════════════════════════════════════════════════════ */
.ai-action {
  display: flex; align-items: center; gap: 12px;
  margin: -6px 0 14px;
  flex-wrap: wrap;
}
.btn-ai {
  background: linear-gradient(135deg, #b08d57 0%, #d4af6f 100%);
  color: white;
  border: none;
  padding: 9px 18px;
  border-radius: 999px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity .15s, transform .1s;
  font-size: .92rem;
}
.btn-ai:hover:not(:disabled) { transform: translateY(-1px); opacity: .92; }
.btn-ai:disabled { opacity: .5; cursor: not-allowed; }
.btn-ai.loading {
  background: #888 !important;
  cursor: wait;
}

.file-list {
  display: flex; flex-direction: column; gap: 6px;
  margin-bottom: 10px;
}
