/**
 * ================================================================
 *  FIXEO v8 — QUICK SEARCH MODAL  (css/quick-search-modal.css)
 *  "Recherche rapide" button in header → full search form + results
 *  ▸ Mirrors the HERO bar layout inside a centred modal overlay
 *  ▸ Unified card design (.qsm-card) → same as ssb2-card / hsm-card
 * ================================================================
 */

/* ══════════════════════════════════════════════════════════════
   BACKDROP
══════════════════════════════════════════════════════════════ */
.qsm-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(7, 7, 18, 0.82);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  z-index: 9200;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.28s ease;
}
.qsm-backdrop.open {
  opacity: 1;
  pointer-events: auto;
}

/* ══════════════════════════════════════════════════════════════
   MODAL CONTAINER
══════════════════════════════════════════════════════════════ */
.qsm-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 9210;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding: 80px 16px 24px;
  overflow-y: auto;
  pointer-events: none;
  opacity: 0;
  transform: translateY(-22px);
  transition: opacity 0.30s ease, transform 0.30s cubic-bezier(0.22, 1, 0.36, 1);
}
.qsm-modal.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: auto;
}

/* ══════════════════════════════════════════════════════════════
   DIALOG BOX
══════════════════════════════════════════════════════════════ */
.qsm-dialog {
  background: var(--bg-card, #13131f);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 24px;
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.70), 0 0 0 1px rgba(255,255,255,0.04);
  width: 100%;
  max-width: 760px;
  overflow: hidden;
  position: relative;
}

/* ══════════════════════════════════════════════════════════════
   HEADER
══════════════════════════════════════════════════════════════ */
.qsm-header {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 20px 20px 16px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  background: linear-gradient(135deg, rgba(225,48,108,0.08) 0%, rgba(131,58,180,0.06) 100%);
}
.qsm-header-icon {
  font-size: 1.5rem;
  flex-shrink: 0;
  background: linear-gradient(135deg, #E1306C, #833AB4);
  width: 42px;
  height: 42px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}
.qsm-header-title {
  font-size: 1.1rem;
  font-weight: 800;
  background: linear-gradient(135deg, #E1306C, #833AB4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  line-height: 1.2;
}
.qsm-header-sub {
  font-size: 0.8rem;
  color: rgba(255, 255, 255, 0.5);
  margin-top: 2px;
}
.qsm-header-close {
  margin-left: auto;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  cursor: pointer;
  color: rgba(255, 255, 255, 0.7);
  font-size: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
  flex-shrink: 0;
}
.qsm-header-close:hover {
  background: rgba(225, 48, 108, 0.2);
  color: #fff;
}

/* ══════════════════════════════════════════════════════════════
   SEARCH FORM SECTION
══════════════════════════════════════════════════════════════ */
.qsm-search-section {
  padding: 20px 20px 0;
}

/* ── Search card (mirrors ssb2-bar-card) ── */
.qsm-bar-card {
  display: flex;
  align-items: stretch;
  background: rgba(255, 255, 255, 0.05);
  border: 1.5px solid rgba(255, 255, 255, 0.12);
  border-radius: 16px;
  overflow: hidden;
  transition: border-color 0.2s, box-shadow 0.2s;
  min-height: 62px;
}
.qsm-bar-card:focus-within {
  border-color: rgba(225, 48, 108, 0.55);
  box-shadow: 0 0 0 3px rgba(225, 48, 108, 0.12);
}

/* ── Segment ── */
.qsm-segment {
  display: flex;
  align-items: center;
  gap: 8px;
  flex: 1;
  padding: 10px 14px;
  cursor: text;
  position: relative;
  min-width: 0;
}
.qsm-segment:not(:last-child) {
  border-right: 1px solid rgba(255, 255, 255, 0.08);
}
.qsm-seg-icon {
  font-size: 1rem;
  flex-shrink: 0;
  opacity: 0.8;
}
.qsm-seg-body {
  display: flex;
  flex-direction: column;
  min-width: 0;
  flex: 1;
}
.qsm-seg-label {
  font-size: 0.68rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.45);
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.qsm-seg-input,
.qsm-seg-select {
  background: transparent;
  border: none;
  outline: none;
  color: #fff;
  font-size: 0.88rem;
  font-weight: 500;
  font-family: inherit;
  padding: 2px 0;
  width: 100%;
  cursor: pointer;
}
.qsm-seg-input::placeholder {
  color: rgba(255, 255, 255, 0.35);
  font-size: 0.82rem;
}
.qsm-seg-select option {
  background: #1a1a2e;
  color: #fff;
}
.qsm-clear-btn {
  background: rgba(255,255,255,0.1);
  border: none;
  border-radius: 50%;
  width: 22px;
  height: 22px;
  cursor: pointer;
  color: rgba(255,255,255,0.6);
  font-size: 0.7rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background 0.2s;
}
.qsm-clear-btn:hover { background: rgba(225,48,108,0.3); color: #fff; }
.qsm-seg-divider {
  width: 1px;
  background: rgba(255,255,255,0.08);
  margin: 10px 0;
  align-self: stretch;
  flex-shrink: 0;
}

/* ── Search CTA button ── */
.qsm-btn-search {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  background: linear-gradient(135deg, #E1306C, #833AB4, #405DE6);
  color: #fff;
  border: none;
  border-radius: 0 14px 14px 0;
  padding: 0 22px;
  font-size: 0.9rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  flex-shrink: 0;
  transition: filter 0.2s, transform 0.15s;
  min-width: 120px;
}
.qsm-btn-search svg {
  width: 18px;
  height: 18px;
}
.qsm-btn-search:hover {
  filter: brightness(1.15);
  transform: translateX(2px);
}
.qsm-btn-search:active {
  transform: scale(0.97);
}

/* ── Quick filters row ── */
.qsm-filters-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px;
  padding: 12px 0 0;
}
.qsm-filters-label {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.45);
  font-weight: 600;
  flex-shrink: 0;
}
.qsm-qfilter {
  display: flex;
  align-items: center;
  gap: 5px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.10);
  border-radius: 30px;
  padding: 5px 12px;
  color: rgba(255, 255, 255, 0.65);
  font-size: 0.78rem;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  transition: all 0.2s;
}
.qsm-qfilter:hover {
  background: rgba(225, 48, 108, 0.12);
  border-color: rgba(225, 48, 108, 0.3);
  color: #fff;
}
.qsm-qfilter.active {
  background: rgba(225, 48, 108, 0.18);
  border-color: rgba(225, 48, 108, 0.5);
  color: #fff;
}
.qsm-qdot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: rgba(255,255,255,0.3);
  transition: background 0.2s;
  flex-shrink: 0;
}
.qsm-qfilter.active .qsm-qdot { background: #20c997; }

/* ══════════════════════════════════════════════════════════════
   RESULTS SECTION
══════════════════════════════════════════════════════════════ */
.qsm-results-section {
  padding: 16px 20px 0;
}
.qsm-results-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.qsm-results-count {
  font-size: 0.85rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.75);
}
.qsm-results-tag {
  font-size: 0.75rem;
  color: rgba(255,255,255,0.4);
}

/* ══════════════════════════════════════════════════════════════
   ARTISAN CARDS  (.qsm-card — unified layout)
══════════════════════════════════════════════════════════════ */
.qsm-cards-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding-bottom: 4px;
}

.qsm-card {
  display: flex;
  align-items: center;
  gap: 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 16px;
  padding: 14px 16px;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
  cursor: default;
}
.qsm-card:hover {
  background: rgba(255, 255, 255, 0.07);
  border-color: rgba(225, 48, 108, 0.25);
  transform: translateX(3px);
}
.qsm-card--featured {
  border-color: rgba(225, 48, 108, 0.35);
  background: linear-gradient(135deg, rgba(225,48,108,0.07) 0%, rgba(131,58,180,0.05) 100%);
}

/* Avatar */
.qsm-card-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E1306C, #833AB4);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 1rem;
  color: #fff;
  flex-shrink: 0;
  position: relative;
}
.qsm-avail-dot {
  position: absolute;
  bottom: 1px;
  right: 1px;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  border: 2px solid var(--bg-card, #13131f);
}
.qsm-avail-dot.available { background: #20c997; }
.qsm-avail-dot.busy      { background: #ffa502; }
.qsm-avail-dot.offline   { background: #6c757d; }

/* Info block */
.qsm-card-info {
  flex: 1;
  min-width: 0;
}
.qsm-card-top {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 4px;
}
.qsm-card-name {
  font-weight: 700;
  font-size: 0.95rem;
  color: #fff;
}
.qsm-badge-available {
  font-size: 0.7rem;
  font-weight: 700;
  background: rgba(32, 201, 151, 0.15);
  color: #20c997;
  border: 1px solid rgba(32, 201, 151, 0.25);
  border-radius: 20px;
  padding: 2px 8px;
}
.qsm-card-meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 5px;
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.6);
  margin-bottom: 6px;
}
.qsm-stars { color: #FFD700; letter-spacing: 0.03em; }
.qsm-meta-sep { color: rgba(255,255,255,0.25); }
.qsm-card-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}
.qsm-badge {
  font-size: 0.68rem;
  font-weight: 600;
  border-radius: 20px;
  padding: 2px 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.10);
  color: rgba(255, 255, 255, 0.65);
}
.qsm-badge.trust {
  background: rgba(32, 201, 151, 0.10);
  border-color: rgba(32, 201, 151, 0.20);
  color: #20c997;
}
.qsm-badge.fast {
  background: rgba(252, 175, 69, 0.10);
  border-color: rgba(252, 175, 69, 0.20);
  color: #FCAF45;
}

/* Actions */
.qsm-card-actions {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex-shrink: 0;
}
.qsm-btn-reserve,
.qsm-btn-express {
  border: none;
  border-radius: 10px;
  padding: 7px 14px;
  font-size: 0.78rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  white-space: nowrap;
  transition: filter 0.2s, transform 0.15s;
  min-width: 100px;
  text-align: center;
}
.qsm-btn-reserve {
  background: linear-gradient(135deg, #E1306C, #833AB4);
  color: #fff;
}
.qsm-btn-reserve:hover { filter: brightness(1.15); transform: scale(1.04); }
.qsm-btn-express {
  background: rgba(252, 175, 69, 0.15);
  border: 1px solid rgba(252, 175, 69, 0.3);
  color: #FCAF45;
}
.qsm-btn-express:hover {
  background: rgba(252, 175, 69, 0.25);
  transform: scale(1.04);
}

/* Empty state */
.qsm-empty {
  text-align: center;
  padding: 40px 20px;
}
.qsm-empty-icon { font-size: 2.5rem; margin-bottom: 12px; }
.qsm-empty-title {
  font-size: 1rem;
  font-weight: 700;
  color: rgba(255,255,255,0.75);
  margin-bottom: 6px;
}
.qsm-empty-sub { font-size: 0.82rem; color: rgba(255,255,255,0.4); }

/* Loading */
.qsm-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 36px 20px;
  gap: 14px;
}
.qsm-spinner {
  width: 36px;
  height: 36px;
  border: 3px solid rgba(255,255,255,0.08);
  border-top-color: #E1306C;
  border-radius: 50%;
  animation: qsm-spin 0.7s linear infinite;
}
@keyframes qsm-spin { to { transform: rotate(360deg); } }
.qsm-loading-text { font-size: 0.88rem; color: rgba(255,255,255,0.5); }

/* ══════════════════════════════════════════════════════════════
   FOOTER (inside modal)
══════════════════════════════════════════════════════════════ */
.qsm-footer {
  padding: 14px 20px 20px;
  border-top: 1px solid rgba(255,255,255,0.07);
  margin-top: 16px;
}
.qsm-footer-security {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.35);
  margin-bottom: 10px;
}
.qsm-footer-security span::before { margin-right: 4px; }
.qsm-footer-see-all {
  display: block;
  width: 100%;
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 12px;
  padding: 10px;
  color: rgba(255,255,255,0.75);
  font-size: 0.85rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  text-align: center;
  transition: background 0.2s, border-color 0.2s;
}
.qsm-footer-see-all:hover {
  background: rgba(225,48,108,0.1);
  border-color: rgba(225,48,108,0.3);
  color: #fff;
}

/* ══════════════════════════════════════════════════════════════
   HEADER BUTTON — "Recherche rapide"
══════════════════════════════════════════════════════════════ */
.btn-quick-search {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: rgba(225, 48, 108, 0.12);
  border: 1.5px solid rgba(225, 48, 108, 0.35);
  border-radius: 30px;
  padding: 7px 16px;
  color: rgba(255,255,255,0.88);
  font-size: 0.82rem;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
  white-space: nowrap;
}
.btn-quick-search:hover {
  background: rgba(225, 48, 108, 0.22);
  border-color: rgba(225, 48, 108, 0.6);
  color: #fff;
  transform: translateY(-1px);
}
.btn-quick-search .bqs-icon {
  font-size: 0.9rem;
}

/* ══════════════════════════════════════════════════════════════
   HERO INLINE RESULTS  (under HERO bar on page)
══════════════════════════════════════════════════════════════ */
#hero-inline-results {
  background: rgba(13, 13, 26, 0.95);
  border-top: 1px solid rgba(225, 48, 108, 0.18);
  border-bottom: 1px solid rgba(255, 255, 255, 0.05);
  padding: 28px 0;
}
.hero-results-inner {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 24px;
}
.hero-results-header-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 18px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.hero-results-count-label {
  font-size: 0.92rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.80);
  display: flex;
  align-items: center;
  gap: 8px;
}
.hero-results-count-label::before {
  content: '';
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: linear-gradient(135deg, #E1306C, #833AB4);
}
.hero-results-close-btn {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 20px;
  padding: 5px 14px;
  color: rgba(255,255,255,0.6);
  font-size: 0.78rem;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}
.hero-results-close-btn:hover {
  background: rgba(225,48,108,0.15);
  color: #fff;
}
#hero-results-grid {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
/* Reuse qsm-card styles for hero inline results */
#hero-results-grid .qsm-card {
  max-width: 100%;
}

/* ══════════════════════════════════════════════════════════════
   RESPONSIVE
══════════════════════════════════════════════════════════════ */
@media (max-width: 640px) {
  .qsm-modal {
    padding: 60px 8px 16px;
    align-items: flex-start;
  }
  .qsm-dialog {
    border-radius: 18px;
  }
  .qsm-bar-card {
    flex-direction: column;
    border-radius: 14px;
  }
  .qsm-segment:not(:last-child) {
    border-right: none;
    border-bottom: 1px solid rgba(255,255,255,0.08);
  }
  .qsm-btn-search {
    border-radius: 0 0 12px 12px;
    padding: 14px;
    justify-content: center;
  }
  .qsm-card {
    flex-wrap: wrap;
  }
  .qsm-card-actions {
    flex-direction: row;
    width: 100%;
  }
  .qsm-btn-reserve,
  .qsm-btn-express {
    flex: 1;
    min-width: 0;
  }
  .btn-quick-search {
    padding: 6px 10px;
    font-size: 0.78rem;
  }
  .btn-quick-search .bqs-text {
    display: none;
  }
}
