/**
 * @file
 * installateur-realisation.css
 * Badge + Carte installateur sur articles mt_post.
 */

/* ============================================================
   BADGE COMPACT (haut d'article)
   ============================================================ */
.inst-badge {
  display: flex; align-items: center; gap: 14px;
  background: color-mix(in srgb, var(--ib-dominante, #1e3a6e) 6%, #fff);
  border-left: 4px solid var(--ib-accent, #e8630a);
  border-radius: 0 8px 8px 0;
  padding: 14px 20px;
  margin-bottom: 28px;
  text-decoration: none !important;
  color: inherit !important;
  transition: background .2s, box-shadow .2s;
}
.inst-badge:hover {
  background: color-mix(in srgb, var(--ib-dominante, #1e3a6e) 10%, #fff);
  box-shadow: 0 2px 12px rgba(0,0,0,.08);
  text-decoration: none !important;
  color: inherit !important;
}

.inst-badge-logo {
  width: 44px; height: 44px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; border-radius: 6px;
}
.inst-badge-logo img {
  width: 100%; height: 100%; object-fit: contain;
}
.inst-badge-initials {
  width: 44px; height: 44px;
  background: var(--ib-dominante, #1e3a6e); border-radius: 6px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: .85rem; letter-spacing: .5px;
}

.inst-badge-info {
  display: flex; flex-direction: column; gap: 2px; flex: 1; min-width: 0;
}
.inst-badge-label {
  font-size: .7rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .5px; color: #6c757d;
}
.inst-badge-name {
  font-size: .95rem; font-weight: 700;
  color: var(--ib-dominante, #1e3a6e);
  white-space: nowrap; overflow: hidden; text-overflow: ellipsis;
}
.inst-badge-loc {
  font-size: .78rem; color: #6c757d;
  display: flex; align-items: center; gap: 4px;
}
.inst-badge-loc svg { flex-shrink: 0; color: var(--ib-accent, #e8630a); }

.inst-badge-certifs {
  display: flex; align-items: center; gap: 5px; flex-shrink: 0;
  background: rgba(255,255,255,.7);
  border: 1px solid color-mix(in srgb, var(--ib-dominante, #1e3a6e) 20%, transparent);
  border-radius: 6px; padding: 6px 12px;
  font-size: .72rem; font-weight: 600;
  color: var(--ib-dominante, #1e3a6e);
}
.inst-badge-certifs svg { color: var(--ib-accent, #e8630a); flex-shrink: 0; }

.inst-badge-arrow {
  flex-shrink: 0; color: #adb5bd;
  transition: transform .2s, color .2s;
}
.inst-badge:hover .inst-badge-arrow {
  transform: translateX(3px);
  color: var(--ib-accent, #e8630a);
}

/* ============================================================
   CARTE SIGNATURE (bas d'article)
   ============================================================ */
.inst-card {
  margin-top: 48px;
  border-radius: 12px; overflow: hidden;
  box-shadow: 0 4px 24px rgba(0,0,0,.1);
  border: 1px solid rgba(0,0,0,.06);
}

.inst-card-header {
  display: flex; align-items: center; justify-content: space-between;
  background: var(--ib-dominante, #1e3a6e);
  padding: 14px 28px;
}
.inst-card-pretitle {
  display: flex; align-items: center; gap: 8px;
  font-size: .78rem; font-weight: 600; text-transform: uppercase;
  letter-spacing: .8px; color: rgba(255,255,255,.9);
}
.inst-card-pretitle svg { color: var(--ib-accent, #e8630a); }
.inst-card-bdf { height: 22px; width: auto; filter: brightness(0) invert(1); opacity: .7; }

.inst-card-body {
  display: flex; gap: 24px; align-items: center;
  padding: 28px;
  background: color-mix(in srgb, var(--ib-dominante, #1e3a6e) 4%, #fff);
}

.inst-card-logo {
  width: 90px; height: 90px; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  overflow: hidden; border-radius: 10px;
  background: #fff; box-shadow: 0 2px 8px rgba(0,0,0,.08);
}
.inst-card-logo img {
  width: 100%; height: 100%; object-fit: contain; padding: 6px;
}
.inst-card-initials {
  width: 90px; height: 90px;
  background: var(--ib-dominante, #1e3a6e); border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  color: #fff; font-weight: 700; font-size: 1.5rem; letter-spacing: 1px;
}

.inst-card-details { flex: 1; min-width: 0; }
.inst-card-name {
  font-size: 1.25rem; font-weight: 700;
  color: var(--ib-dominante, #1e3a6e);
  margin: 0 0 6px;
}
.inst-card-loc {
  display: flex; align-items: center; gap: 6px;
  font-size: .88rem; color: #6c757d; margin: 0 0 10px;
}
.inst-card-loc svg { flex-shrink: 0; color: var(--ib-accent, #e8630a); }

.inst-card-certifs {
  display: flex; gap: 8px; flex-wrap: wrap; margin-bottom: 8px;
}
.inst-card-certif {
  display: inline-flex; align-items: center; gap: 4px;
  background: color-mix(in srgb, var(--ib-dominante, #1e3a6e) 10%, #fff);
  border-radius: 4px; padding: 4px 10px;
  font-size: .72rem; font-weight: 600;
  color: var(--ib-dominante, #1e3a6e);
}
.inst-card-certif svg { color: var(--ib-accent, #e8630a); }

.inst-card-since {
  font-size: .78rem; color: #6c757d; font-style: italic; margin: 0;
}

.inst-card-footer {
  padding: 20px 28px 24px;
  background: #fff;
  border-top: 1px solid rgba(0,0,0,.06);
}
.inst-card-pitch {
  font-size: .88rem; color: #495057; line-height: 1.6;
  margin: 0 0 16px;
}

.inst-card-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.inst-card-btn {
  display: inline-flex; align-items: center; gap: 8px;
  border-radius: 6px; padding: 10px 20px;
  font-size: .85rem; font-weight: 600;
  text-decoration: none !important; transition: all .2s;
}
.inst-card-btn--primary {
  background: var(--ib-accent, #e8630a); color: #fff !important;
  border: 2px solid var(--ib-accent, #e8630a);
}
.inst-card-btn--primary:hover {
  filter: brightness(1.1); transform: translateY(-1px);
  color: #fff !important; text-decoration: none !important;
}
.inst-card-btn--outline {
  background: transparent;
  color: var(--ib-dominante, #1e3a6e) !important;
  border: 2px solid var(--ib-dominante, #1e3a6e);
}
.inst-card-btn--outline:hover {
  background: var(--ib-dominante, #1e3a6e);
  color: #fff !important; text-decoration: none !important;
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 768px) {
  .inst-badge {
    flex-wrap: wrap; gap: 10px;
    padding: 12px 16px;
  }
  .inst-badge-certifs { display: none; }
  .inst-badge-arrow { display: none; }

  .inst-card-body {
    flex-direction: column; text-align: center;
    padding: 24px 20px;
  }
  .inst-card-loc { justify-content: center; }
  .inst-card-certifs { justify-content: center; }
  .inst-card-footer { padding: 16px 20px 20px; }
  .inst-card-actions { flex-direction: column; }
  .inst-card-btn { justify-content: center; width: 100%; }
}
