/* ═══════════════════════════════════════════════════════════════════════════════
   IMMOBILIER.FR — BRAND OVERRIDE CSS
   Ce fichier force les couleurs du brand guide sur le template Vuexy
   DOIT ETRE CHARGE EN DERNIER dans _Layout.cshtml
   ═══════════════════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════════════════════
   VARIABLES CSS — COULEURS DU BRAND
   ═══════════════════════════════════════════════════════════════════════════════ */
:root {
  --immo-bordeaux: #5C2A34 !important;
  --immo-or: #C9A96E !important;
  --immo-ivoire: #FAF8F5 !important;
  --immo-marine: #1A2A3A !important;
  --immo-taupe: #EDE5DC !important;
  --immo-bordeaux-light: #7A3D4A !important;
  --immo-bordeaux-dark: #4A222A !important;
  --immo-or-light: #D4BA85 !important;
  --immo-or-dark: #B8935A !important;
  --bs-primary: #5C2A34 !important;
  --bs-primary-rgb: 92, 42, 52 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   SIDEBAR / MENU - LOGO - HAUTEUR +20%
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Fond sidebar */
.layout-menu,
.menu-vertical,
.bg-menu-theme {
  background-color: #EDE5DC !important;
}

/* Header sidebar avec logo - fond bordeaux - HAUTEUR AUGMENTÉE +20% */
.app-brand,
.app-brand.demo {
  background-color: #5C2A34 !important;
  padding: 1.8rem 1rem !important;
  margin-bottom: 0.25rem !important;
  display: flex !important;
  justify-content: center !important;
  align-items: center !important;
  position: relative !important;
  min-height: 90px !important;
}

.app-brand-text {
  color: #FAF8F5 !important;
  font-weight: 700 !important;
  font-size: 1.1rem !important;
}

/* Logo dans sidebar - centré */
.app-brand-link {
  margin: 0 auto !important;
  display: flex !important;
  justify-content: center !important;
}

.app-brand-link img {
  height: 65px !important;
  width: auto !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   MENU HEADERS / SECTIONS - COULEUR PLUS SOMBRE
   ═══════════════════════════════════════════════════════════════════════════════ */

.menu-header,
.menu-header small,
.menu-header .menu-header-text {
  color: #5C2A34 !important;
  font-weight: 700 !important;
  text-transform: uppercase !important;
  font-size: 0.65rem !important;
  letter-spacing: 0.8px !important;
  padding: 0.4rem 1rem !important;
  margin-top: 0.4rem !important;
  opacity: 0.7 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   MENU ITEMS - PRINCIPAL - ESPACEMENT ENCORE RÉDUIT -15%
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Reset complet des styles menu */
.menu-inner {
  padding: 0.2rem 0 !important;
}

/* Menu items principaux */
.menu-inner > .menu-item {
  margin: 0 !important;
  padding: 0 !important;
}

.menu-inner > .menu-item > .menu-link {
  color: #5C2A34 !important;
  border-radius: 5px !important;
  margin: 1px 6px !important;
  padding: 0.4rem 0.75rem !important;
  display: flex !important;
  align-items: center !important;
}

.menu-inner > .menu-item > .menu-link:hover {
  background-color: rgba(92, 42, 52, 0.1) !important;
  color: #5C2A34 !important;
}

.menu-inner > .menu-item.active > .menu-link {
  background-color: #5C2A34 !important;
  color: #FAF8F5 !important;
  box-shadow: 0 2px 6px rgba(92, 42, 52, 0.4) !important;
}

.menu-inner > .menu-item.active > .menu-link .menu-icon,
.menu-inner > .menu-item.active > .menu-link i {
  color: #FAF8F5 !important;
}

/* Menu icons */
.menu-icon {
  color: #5C2A34 !important;
  margin-right: 0.4rem !important;
  flex-shrink: 0 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   MENU TOGGLE (flèche) - SUPPRIMER CARRÉS NOIRS
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Masquer les éléments ::after qui causent les carrés noirs */
.menu-toggle::after {
  display: none !important;
}

/* Flèche de toggle personnalisée */
.menu-item.open > .menu-link.menu-toggle::before {
  content: "" !important;
  position: absolute !important;
  right: 1rem !important;
  width: 0 !important;
  height: 0 !important;
  border-left: 5px solid transparent !important;
  border-right: 5px solid transparent !important;
  border-top: 5px solid #5C2A34 !important;
}

.menu-item:not(.open) > .menu-link.menu-toggle::before {
  content: "" !important;
  position: absolute !important;
  right: 1rem !important;
  width: 0 !important;
  height: 0 !important;
  border-top: 5px solid transparent !important;
  border-bottom: 5px solid transparent !important;
  border-left: 5px solid #5C2A34 !important;
}

.menu-link.menu-toggle {
  position: relative !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   MENU SOUS-ITEMS - FIX COMPLET - ESPACEMENT RÉDUIT
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Container des sous-menus */
.menu-sub {
  background-color: rgba(92, 42, 52, 0.03) !important;
  padding: 0.15rem 0 !important;
  margin: 0 !important;
  list-style: none !important;
}

/* Items des sous-menus */
.menu-sub .menu-item {
  margin: 0 !important;
  padding: 0 !important;
}

/* Liens des sous-menus */
.menu-sub .menu-link {
  color: #5C2A34 !important;
  padding: 0.3rem 0.75rem 0.3rem 2.25rem !important;
  margin: 0 6px !important;
  border-radius: 4px !important;
  display: flex !important;
  align-items: center !important;
  font-size: 0.85rem !important;
}

.menu-sub .menu-link:hover {
  background-color: rgba(92, 42, 52, 0.08) !important;
  color: #5C2A34 !important;
}

/* Sous-menu item actif */
.menu-sub .menu-item.active > .menu-link {
  background-color: #5C2A34 !important;
  color: #FAF8F5 !important;
  font-weight: 500 !important;
}

/* Texte dans les sous-menus - visible en entier */
.menu-sub .menu-link div,
.menu-sub .menu-link span {
  white-space: nowrap !important;
  overflow: visible !important;
  text-overflow: clip !important;
  color: inherit !important;
}

/* Supprimer tout ::before ou ::after parasite dans les sous-menus */
.menu-sub .menu-link::before,
.menu-sub .menu-link::after {
  display: none !important;
  content: none !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   BADGES DANS LE MENU - FIX CARRÉS NOIRS
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Badges dans le menu principal */
.menu-inner .badge {
  background-color: #C9A96E !important;
  color: #5C2A34 !important;
  font-size: 0.65rem !important;
  padding: 0.15rem 0.4rem !important;
  border-radius: 4px !important;
  margin-left: auto !important;
  font-weight: 600 !important;
}

/* Badges danger (notifications) */
.menu-inner .badge.bg-danger {
  background-color: #dc3545 !important;
  color: #fff !important;
}

/* Badges warning */
.menu-inner .badge.bg-warning {
  background-color: #ffc107 !important;
  color: #000 !important;
}

/* Badges primary */
.menu-inner .badge.bg-primary {
  background-color: #5C2A34 !important;
  color: #fff !important;
}

/* Badge label-primary */
.menu-inner .badge.bg-label-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  color: #5C2A34 !important;
}

/* Badge label-warning */
.menu-inner .badge.bg-label-warning {
  background-color: rgba(255, 193, 7, 0.2) !important;
  color: #B8860B !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   CARD HEADERS - FIX "INFORMATIONS FINANCIÈRES"
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Card header avec fond bordeaux */
.card-header.bg-primary,
.card-header[class*="bg-primary"] {
  background-color: #5C2A34 !important;
  color: #FAF8F5 !important;
  border-bottom: none !important;
}

.card-header.bg-primary h5,
.card-header.bg-primary h6,
.card-header.bg-primary .card-title,
.card-header.bg-primary span,
.card-header.bg-primary i,
.card-header[class*="bg-primary"] h5,
.card-header[class*="bg-primary"] h6,
.card-header[class*="bg-primary"] .card-title,
.card-header[class*="bg-primary"] span,
.card-header[class*="bg-primary"] i {
  color: #FAF8F5 !important;
}

/* Card header avec fond label-primary (plus clair) */
.card-header.bg-label-primary {
  background-color: rgba(92, 42, 52, 0.12) !important;
  color: #5C2A34 !important;
  border-bottom: 1px solid rgba(92, 42, 52, 0.1) !important;
}

.card-header.bg-label-primary h5,
.card-header.bg-label-primary h6,
.card-header.bg-label-primary .card-title,
.card-header.bg-label-primary span,
.card-header.bg-label-primary i {
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   BOUTONS - PRIORITE MAXIMALE
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Bouton Primary - BORDEAUX */
.btn-primary,
.btn-primary:focus,
.btn-primary:active,
.btn-primary:not(:disabled):not(.disabled):active,
.btn-primary:not(:disabled):not(.disabled).active {
  background-color: #5C2A34 !important;
  border-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

.btn-primary:hover {
  background-color: #4A222A !important;
  border-color: #4A222A !important;
  color: #FFFFFF !important;
}

/* Bouton Success - OR */
.btn-success,
.btn-success:focus,
.btn-success:active {
  background-color: #C9A96E !important;
  border-color: #C9A96E !important;
  color: #5C2A34 !important;
}

.btn-success:hover {
  background-color: #B8935A !important;
  border-color: #B8935A !important;
  color: #5C2A34 !important;
}

/* Bouton Outline Primary */
.btn-outline-primary {
  color: #5C2A34 !important;
  border-color: #5C2A34 !important;
  background-color: transparent !important;
}

.btn-outline-primary:hover,
.btn-outline-primary:focus,
.btn-outline-primary:active {
  background-color: #5C2A34 !important;
  border-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

/* Bouton Label Primary */
.btn-label-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  color: #5C2A34 !important;
  border-color: transparent !important;
}

.btn-label-primary:hover {
  background-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   BADGES GLOBAUX
   ═══════════════════════════════════════════════════════════════════════════════ */

.badge.bg-primary,
.badge.badge-primary {
  background-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

.badge.bg-success,
.badge.badge-success {
  background-color: #C9A96E !important;
  color: #5C2A34 !important;
}

.badge.bg-label-primary,
.badge.badge-label-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   BACKGROUNDS
   ═══════════════════════════════════════════════════════════════════════════════ */

.bg-primary:not(.badge) {
  background-color: #5C2A34 !important;
}

.bg-success:not(.badge) {
  background-color: #C9A96E !important;
  color: #5C2A34 !important;
}

.bg-label-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  color: #5C2A34 !important;
}

.bg-label-success {
  background-color: rgba(201, 169, 110, 0.2) !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   TEXTE
   ═══════════════════════════════════════════════════════════════════════════════ */

.text-primary {
  color: #5C2A34 !important;
}

.text-success {
  color: #C9A96E !important;
}

a {
  color: #5C2A34;
}

a:hover {
  color: #C9A96E;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   CARDS & AVATARS - ICONES
   ═══════════════════════════════════════════════════════════════════════════════ */

/* Avatar avec fond coloré */
.avatar-initial.bg-label-primary,
.avatar-initial.bg-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  color: #5C2A34 !important;
}

.avatar-initial.bg-label-success,
.avatar-initial.bg-success {
  background-color: rgba(201, 169, 110, 0.2) !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   FOND DE PAGE & NAVBAR
   ═══════════════════════════════════════════════════════════════════════════════ */

body,
.layout-wrapper,
.layout-page,
.content-wrapper {
  background-color: #FAF8F5 !important;
}

.layout-navbar,
.bg-navbar-theme {
  background-color: #FFFFFF !important;
  border-bottom: 1px solid #EDE5DC !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   CARDS
   ═══════════════════════════════════════════════════════════════════════════════ */

.card {
  border: 1px solid #EDE5DC !important;
  box-shadow: 0 2px 6px rgba(92, 42, 52, 0.06) !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   PROGRESS BARS
   ═══════════════════════════════════════════════════════════════════════════════ */

.progress-bar,
.progress-bar.bg-primary {
  background-color: #5C2A34 !important;
}

.progress-bar.bg-success {
  background-color: #C9A96E !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   TABLES
   ═══════════════════════════════════════════════════════════════════════════════ */

.table thead th {
  background-color: #EDE5DC !important;
  color: #5C2A34 !important;
  font-weight: 600 !important;
  border-bottom: 2px solid #C9A96E !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   FORMS
   ═══════════════════════════════════════════════════════════════════════════════ */

.form-control:focus,
.form-select:focus {
  border-color: #5C2A34 !important;
  box-shadow: 0 0 0 0.2rem rgba(92, 42, 52, 0.25) !important;
}

.form-check-input:checked {
  background-color: #5C2A34 !important;
  border-color: #5C2A34 !important;
}

/* Input group addon (€ symbol) */
.input-group-text {
  background-color: #EDE5DC !important;
  border-color: #d5ccc3 !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   PAGINATION
   ═══════════════════════════════════════════════════════════════════════════════ */

.page-item.active .page-link {
  background-color: #5C2A34 !important;
  border-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

.page-link {
  color: #5C2A34 !important;
}

.page-link:hover {
  background-color: #EDE5DC !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   ALERTS
   ═══════════════════════════════════════════════════════════════════════════════ */

.alert-primary {
  background-color: rgba(92, 42, 52, 0.15) !important;
  border-color: rgba(92, 42, 52, 0.3) !important;
  color: #5C2A34 !important;
}

.alert-success {
  background-color: rgba(201, 169, 110, 0.15) !important;
  border-color: rgba(201, 169, 110, 0.3) !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   NAV TABS & PILLS
   ═══════════════════════════════════════════════════════════════════════════════ */

.nav-pills .nav-link.active {
  background-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

.nav-tabs .nav-link.active {
  border-bottom-color: #5C2A34 !important;
  color: #5C2A34 !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   DROPDOWN
   ═══════════════════════════════════════════════════════════════════════════════ */

.dropdown-item:hover,
.dropdown-item:focus {
  background-color: rgba(92, 42, 52, 0.08) !important;
  color: #5C2A34 !important;
}

.dropdown-item.active,
.dropdown-item:active {
  background-color: #5C2A34 !important;
  color: #FFFFFF !important;
}

/* ═══════════════════════════════════════════════════════════════════════════════
   SCROLLBAR PERSONNALISÉE POUR LE MENU
   ═══════════════════════════════════════════════════════════════════════════════ */

.menu-inner::-webkit-scrollbar {
  width: 5px;
}

.menu-inner::-webkit-scrollbar-thumb {
  background-color: rgba(92, 42, 52, 0.3);
  border-radius: 3px;
}

.menu-inner::-webkit-scrollbar-track {
  background-color: transparent;
}
