/* ============ Styles communs aux 3 modèles ============ */
.tmpl{
  width:340px;
  border-radius:6px;
  overflow:hidden;
  font-family:'Inter',-apple-system,sans-serif;
  position:relative;
}
.tmpl .name{margin:0;}
.tmpl .role{margin:0;}
.tmpl .photo{
  background-size:cover;
  background-position:center;
  display:flex;align-items:center;justify-content:center;
  font-family:'Archivo Expanded','Inter',sans-serif;
  font-weight:800;
}
.tmpl .logo{max-height:26px; max-width:96px; width:auto; object-fit:contain;}
.tmpl .logo.txt{
  font-family:'IBM Plex Mono',monospace;
  font-size:11px; letter-spacing:.1em; text-transform:uppercase;
}

/* ── Poste bilingue (commun) ── */
.tmpl .role-en{
  font-style:italic;
  font-size:0.85em;
  opacity:0.75;
  margin-top:2px;
}

/* ── Bloc coordonnées société (commun) ── */
.tmpl .company-info{
  margin-top:12px;
  padding-top:10px;
  border-top:1px solid rgba(128,128,128,.15);
  font-size:11.5px;
  line-height:1.5;
}
.tmpl .company-tel{opacity:0.7;}
.tmpl .company-web{margin-top:3px;}

/* ============ BÉTON (EXÉCUTIF & ARCHITECTURAL) ============ */
.tmpl-beton{
  background: linear-gradient(165deg, #faf9f6 0%, #f1eee7 100%);
  color: #1a1a1a;
  padding: 24px 22px 22px;
  box-shadow: 0 10px 30px rgba(0, 30, 80, 0.08), inset 0 0 0 1px #e2ded5;
  border-top: 5px solid #003ba7; /* CREDAF Bleu */
  display: flex;
  flex-direction: column;
  min-height: 560px;
  position: relative;
  overflow: hidden;
}
/* Accent doré sous la bordure bleue */
.tmpl-beton .beton-accent-bar{
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 3px;
  background: linear-gradient(90deg, #ffda00 0%, #ffe922 50%, #ffea90 100%);
  z-index: 2;
}
/* Trame subtile géométrique */
.tmpl-beton::after{
  content: "";
  position: absolute;
  inset: 0;
  background-image: radial-gradient(rgba(0, 59, 167, 0.035) 1px, transparent 1px);
  background-size: 16px 16px;
  pointer-events: none;
  z-index: 1;
}
.tmpl-beton > *{
  position: relative;
  z-index: 2;
}
.tmpl-beton .beton-top{
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(0,0,0,0.06);
  margin-bottom: 16px;
}
.tmpl-beton .beton-company{
  display: flex;
  align-items: center;
  gap: 10px;
}
.tmpl-beton .logo{
  max-height: 38px;
  max-width: 120px;
  object-fit: contain;
}
.tmpl-beton .company-name{
  font-family: 'IBM Plex Mono', monospace;
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #475569;
}
.tmpl-beton .beton-tag{
  font-family: 'IBM Plex Mono', monospace;
  font-size: 8.5px;
  letter-spacing: .1em;
  text-transform: uppercase;
  background: rgba(0, 59, 167, 0.08);
  color: #003ba7;
  border: 1px solid rgba(0, 59, 167, 0.2);
  padding: 4px 8px;
  border-radius: 12px;
  font-weight: 600;
  white-space: nowrap;
}
/* Hero Identity Block */
.tmpl-beton .beton-hero{
  display: flex;
  align-items: center;
  gap: 14px;
  background: #ffffff;
  border: 1px solid rgba(0, 59, 167, 0.1);
  border-radius: 8px;
  padding: 14px;
  margin-bottom: 14px;
  box-shadow: 0 4px 12px rgba(0, 20, 60, 0.04);
}
.tmpl-beton .photo.beton-photo{
  width: 62px;
  height: 62px;
  border-radius: 8px;
  background: #003ba7;
  color: #ffda00;
  font-size: 22px;
  font-weight: 700;
  flex-shrink: 0;
  box-shadow: 0 0 0 2px #ffffff, 0 0 0 4px #003ba7, 0 4px 12px rgba(0, 59, 167, 0.25);
}
.tmpl-beton .beton-title-wrap{
  flex: 1;
  min-width: 0;
}
.tmpl-beton .name{
  font-size: 19px;
  font-weight: 800;
  line-height: 1.15;
  color: #003ba7; /* CREDAF Bleu */
  letter-spacing: -0.01em;
  margin: 0 0 4px;
  text-transform: uppercase;
  word-break: break-word;
}
.tmpl-beton .role{
  font-size: 12.5px;
  color: #1e293b;
  font-weight: 600;
  line-height: 1.35;
  margin: 0;
}
.tmpl-beton .role-en{
  color: #64748b;
  font-size: 11px;
  line-height: 1.35;
  margin-top: 3px;
  font-style: italic;
}
/* Body : Datasheet */
.tmpl-beton .beton-body{
  flex: 1;
  margin-bottom: 14px;
}
.tmpl-beton .datasheet{
  background: #ffffff;
  border: 1px solid rgba(0, 0, 0, 0.06);
  border-radius: 8px;
  padding: 10px 14px;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.02);
}
.tmpl-beton .row{
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px dashed rgba(0,0,0,0.08);
  font-size: 12px;
}
.tmpl-beton .row:last-child{
  border-bottom: none;
  padding-bottom: 2px;
}
.tmpl-beton .row:first-child{
  padding-top: 2px;
}
.tmpl-beton .label{
  font-family: 'IBM Plex Mono', monospace;
  color: #64748b;
  font-size: 10.5px;
  letter-spacing: .05em;
  text-transform: uppercase;
}
.tmpl-beton .value{
  font-weight: 600;
  color: #0f172a;
  text-align: right;
  word-break: break-all;
}
.tmpl-beton .beton-link{
  color: #003ba7;
  text-decoration: none;
  font-weight: 600;
  transition: color .15s;
}
.tmpl-beton .beton-link:hover{
  color: #002c80;
  text-decoration: underline;
}
/* Footer : Coordonnées société */
.tmpl-beton .beton-footer{
  margin-top: auto;
}
.tmpl-beton .company-info{
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-left: 3px solid #ffda00; /* Liseré doré */
  border-radius: 6px;
  padding: 10px 12px;
  font-family: 'IBM Plex Mono', monospace;
  color: #475569;
  font-size: 10px;
  line-height: 1.55;
  margin-top: 0;
}
.tmpl-beton .company-address{
  font-weight: 500;
  color: #334155;
  margin-bottom: 3px;
}
.tmpl-beton .company-tel{
  color: #64748b;
}
.tmpl-beton .company-web{
  margin-top: 3px;
}
.tmpl-beton .company-web a{
  color: #003ba7;
  text-decoration: none;
  font-weight: 600;
}

/* ============ CORPORATE (PARFAITEMENT CENTRÉ) ============ */
.tmpl-corporate{
  background:#ffffff;
  color:#222;
  box-shadow:0 0 0 1px rgba(0,0,0,.06) inset;
  display: flex;
  flex-direction: column;
  min-height: 560px; /* Force un format portrait */
}

/* Header : logo + nom société centrés */
.tmpl-corporate .corp-header{
  padding: 36px 20px 16px;
  text-align: center;
}
.tmpl-corporate .corp-logo{
  max-height: 90px;
  max-width: 200px;
  display: block;
  margin: 0 auto 12px;
  object-fit: contain;
}
.tmpl-corporate .corp-logo.txt{
  display: block;
  font-size: 20px;
  font-weight: 700;
  text-align: center;
  margin-bottom: 10px;
}
.tmpl-corporate .corp-company-name{
  font-size: 13px;
  color: #333;
  font-weight: 600;
  text-align: center;
}

/* Corps : Infos personne + badge */
.tmpl-corporate .corp-body{
  flex: 1; /* Pousse le footer vers le bas */
  display: flex;
  flex-direction: column;
  justify-content: center;
  position: relative;
  padding: 0 20px;
}
.tmpl-corporate .corp-person{
  text-align: center;
}
.tmpl-corporate .corp-person .name{
  font-size: 22px;
  font-weight: 700;
  color: #003ba7; /* CREDAF Bleu */
  letter-spacing: .01em;
}
.tmpl-corporate .corp-person .role{
  font-size: 15px;
  color: #333;
  margin-top: 6px;
  font-weight: 500;
  line-height: 1.35;
}
.tmpl-corporate .corp-person .role-en{
  font-size: 13px;
  color: #555;
  font-weight: 400;
  margin-top: 3px;
  line-height: 1.35;
}
.tmpl-corporate .badge{
  position: absolute;
  bottom: 0;
  right: 15px;
  height: 38px;
  width: auto;
}

/* Footer : coordonnées (adresse, ligne, tel/email, site web) */
.tmpl-corporate .corp-footer{
  padding: 16px 20px 24px;
  text-align: center;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  width: 100%;
  margin-top: auto;
}
.tmpl-corporate .corp-address{
  font-size: 11px;
  color: #475569;
  margin-bottom: 6px;
  font-weight: 500;
  line-height: 1.45;
  text-align: center;
  width: 100%;
  max-width: 280px;
  white-space: normal;
  word-break: normal;
  overflow-wrap: break-word;
}
.tmpl-corporate .corp-separator{
  height: 2px;
  width: 70px;
  background: linear-gradient(90deg, #003ba7 0%, #ffda00 50%, #003ba7 100%); /* CREDAF Bleu & Jaune */
  margin: 6px auto 10px;
  border-radius: 2px;
}
.tmpl-corporate .corp-contact-info{
  font-size: 11.5px;
  color: #334155;
  line-height: 1.6;
  font-weight: 500;
  text-align: center;
  width: 100%;
  max-width: 290px;
  white-space: normal;
  word-break: break-word;
}
.tmpl-corporate .corp-web-link{
  color: #003ba7;
  text-decoration: none;
  font-weight: 600;
}
.tmpl-corporate .corp-web-link:hover{
  text-decoration: underline;
}

/* ============ NUIT (ULTRA PREMIUM) ============ */
.tmpl-dark {
  background-color: #030303;
  color: #ffffff;
  padding: 0;
  position: relative;
  display: flex;
  flex-direction: column;
  min-height: 580px;
  overflow: hidden;
  font-family: 'Inter', sans-serif;
}

/* Subtle glowing orb in the background */
.tmpl-dark .dark-mesh {
  position: absolute;
  top: -100px;
  left: 50%;
  transform: translateX(-50%);
  width: 300px;
  height: 300px;
  background: radial-gradient(circle, rgba(0, 59, 167, 0.4) 0%, rgba(255, 218, 0, 0.15) 45%, transparent 70%);
  filter: blur(40px);
  pointer-events: none;
  z-index: 1;
}

/* Grid background */
.tmpl-dark::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image: linear-gradient(rgba(255, 255, 255, 0.03) 1px, transparent 1px),
                    linear-gradient(90deg, rgba(255, 255, 255, 0.03) 1px, transparent 1px);
  background-size: 24px 24px;
  pointer-events: none;
  z-index: 1;
}

.tmpl-dark .dark-content {
  position: relative;
  z-index: 10;
  display: flex;
  flex-direction: column;
  flex: 1;
  padding: 48px 32px 40px;
}

/* Header */
.tmpl-dark .dark-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 56px;
}
.tmpl-dark .dark-logo {
  max-height: 48px;
  max-width: 160px;
  filter: brightness(0) invert(1);
  margin-bottom: 12px;
}
.tmpl-dark .dark-header-name {
  font-size: 9px;
  letter-spacing: 0.15em;
  color: rgba(255,255,255,0.4);
  text-transform: uppercase;
  white-space: nowrap;
}

/* Person Section */
.tmpl-dark .dark-person {
  text-align: left;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: flex-start;
  gap: 20px;
}
.tmpl-dark .dark-person-info {
  display: flex;
  flex-direction: column;
}

/* Elegant Avatar (Replaces the ugly pill) */
.tmpl-dark .photo {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(255,255,255,0.08);
  color: #fff;
  font-size: 24px;
  font-weight: 300;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 0;
  flex-shrink: 0;
  position: relative;
  background-size: cover;
  background-position: center;
  box-shadow: inset 0 0 20px rgba(0,0,0,0.5);
}
/* Tiny Status Dot (CREDAF Jaune) */
.tmpl-dark .photo::after {
  content: "";
  position: absolute;
  bottom: 4px;
  right: 4px;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  background: #ffda00; /* Jaune CREDAF */
  box-shadow: 0 0 8px rgba(255, 218, 0, 0.8);
  border: 2px solid #030303;
}

.tmpl-dark .name {
  font-size: 26px;
  font-weight: 500;
  color: #ffffff;
  margin-bottom: 6px;
  letter-spacing: -0.02em;
}
.tmpl-dark .role {
  font-size: 13px;
  color: #9ca3af;
  font-weight: 400;
}
.tmpl-dark .role-en {
  font-size: 11px;
  color: #6b7280;
  margin-top: 4px;
  font-style: italic;
}

/* Divider */
.tmpl-dark .dark-divider {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(0, 59, 167, 0.5), rgba(255, 234, 144, 0.35), transparent);
  margin: 48px 0 32px;
  width: 100%;
}

/* Details Section */
.tmpl-dark .dark-details {
  width: 100%;
  margin-top: auto;
}
.tmpl-dark .row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 12px 0;
  border-bottom: 1px dashed rgba(255,255,255,0.1);
}
.tmpl-dark .row:last-child {
  border-bottom: none;
}
.tmpl-dark .label {
  font-family: 'IBM Plex Mono', monospace;
  color: rgba(255,255,255,0.4);
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}
.tmpl-dark .value {
  color: #ffffff;
  font-size: 14px;
  font-weight: 400;
  text-align: right;
}

.tmpl-dark .company-info {
  margin-top: 32px;
  text-align: center;
  color: rgba(255,255,255,0.4);
  font-size: 10px;
  line-height: 1.8;
  font-weight: 400;
  white-space: nowrap;
}
.tmpl-dark .company-info > div {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
