/**
 * Suada Sovereign Sales Intelligence — Écran d'Accueil Déconnecté (Dinia Entreprise)
 * Standard : Dark Glassmorphism, Dorures Suada #CC9F33, Cyan Dinia #33CCB1, Lucide SVG, Règle 22 (Zero Emoji).
 */

/* --- ÉCRAN HERO NON AUTHENTIFIÉ --- */
.unauth-hero-container {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  max-width: 860px;
  margin: 10px auto 40px auto;
  padding: 0 16px;
  animation: unauthFadeIn 0.35s ease-out forwards;
}

@keyframes unauthFadeIn {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.unauth-hero-card {
  position: relative;
  width: 100%;
  background: radial-gradient(circle at 50% 0%, rgba(204, 159, 51, 0.08) 0%, rgba(13, 20, 36, 0.85) 70%), rgba(10, 14, 26, 0.92);
  backdrop-filter: blur(28px);
  -webkit-backdrop-filter: blur(28px);
  border: 1px solid rgba(204, 159, 51, 0.32);
  border-radius: 20px;
  padding: 44px 36px 36px 36px;
  text-align: center;
  box-shadow: 0 24px 60px rgba(0, 0, 0, 0.6), 0 0 40px rgba(204, 159, 51, 0.12);
  overflow: hidden;
}

/* Badge supérieur d'alerte souveraine */
.unauth-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: 24px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  color: #fbbf24;
  font-size: 0.78rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin-bottom: 22px;
}

.unauth-badge i {
  width: 14px;
  height: 14px;
}

/* Cercle icône central */
.unauth-icon-circle {
  width: 76px;
  height: 76px;
  margin: 0 auto 20px auto;
  border-radius: 50%;
  background: linear-gradient(135deg, rgba(204, 159, 51, 0.22), rgba(51, 204, 177, 0.12));
  border: 1px solid rgba(204, 159, 51, 0.45);
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 0 30px rgba(204, 159, 51, 0.25);
}

.unauth-icon-circle i {
  width: 36px;
  height: 36px;
  color: var(--suada-gold, #CC9F33);
}

/* Typographie */
.unauth-title {
  font-size: 1.85rem;
  font-weight: 700;
  color: #f8fafc;
  margin: 0 0 12px 0;
  line-height: 1.25;
  letter-spacing: -0.02em;
}

.unauth-subtitle {
  font-size: 0.98rem;
  color: #94a3b8;
  max-width: 640px;
  margin: 0 auto 28px auto;
  line-height: 1.6;
}

.unauth-subtitle strong {
  color: #e2e8f0;
}

/* Grille des 3 capacités phares */
.unauth-features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 32px;
  text-align: left;
}

.unauth-feature-item {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.07);
  border-radius: 12px;
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.unauth-feature-item:hover {
  border-color: rgba(204, 159, 51, 0.35);
  transform: translateY(-2px);
}

.unauth-feature-icon {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: rgba(204, 159, 51, 0.12);
  display: flex;
  align-items: center;
  justify-content: center;
}

.unauth-feature-icon i {
  width: 18px;
  height: 18px;
  color: var(--suada-gold, #CC9F33);
}

.unauth-feature-text strong {
  display: block;
  font-size: 0.88rem;
  color: #f1f5f9;
  margin-bottom: 4px;
}

.unauth-feature-text span {
  display: block;
  font-size: 0.78rem;
  color: #64748b;
  line-height: 1.45;
}

/* Bouton CTA Principal HERO */
.unauth-cta-group {
  margin-bottom: 26px;
}

.btn-unauth-login {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: linear-gradient(135deg, #CC9F33 0%, #b88a24 100%);
  color: #070a12;
  font-size: 1.05rem;
  font-weight: 700;
  padding: 16px 36px;
  border-radius: 12px;
  text-decoration: none;
  border: 1px solid rgba(255, 255, 255, 0.3);
  box-shadow: 0 10px 28px rgba(204, 159, 51, 0.35), 0 0 0 1px rgba(0, 0, 0, 0.2);
  cursor: pointer;
  transition: transform 0.2s cubic-bezier(0.34, 1.56, 0.64, 1), box-shadow 0.2s ease, background 0.2s ease;
}

.btn-unauth-login:hover {
  transform: translateY(-2px) scale(1.01);
  box-shadow: 0 14px 36px rgba(204, 159, 51, 0.45);
  background: linear-gradient(135deg, #d8ac41 0%, #c4962c 100%);
  color: #000;
}

.btn-unauth-login:active {
  transform: translateY(1px) scale(0.99);
}

.btn-unauth-login i {
  width: 20px;
  height: 20px;
}

/* Réassurance de sécurité */
.unauth-security-footer {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 16px;
  padding-top: 20px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.unauth-sec-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 0.76rem;
  color: #64748b;
}

.unauth-sec-pill i {
  width: 14px;
  height: 14px;
  color: #33CCB1;
}

/* --- VERROUILLAGE DES ACTIONS DU HEADER & BOUTONS --- */
body.suada-unauthenticated #suadaActionToolbar .btn-icon,
body.suada-unauthenticated #mobileBottomBar .btn-icon,
body.suada-unauthenticated .suada-subnav-bar,
body.suada-unauthenticated #btnRecord,
body.suada-unauthenticated #btnLeadCockpit,
body.suada-unauthenticated #btnNewLead,
body.suada-unauthenticated #btnRefreshLeads,
body.suada-unauthenticated #btnAddCoSeller {
  opacity: 0.55;
  transition: opacity 0.2s ease, border-color 0.2s ease;
  cursor: pointer !important;
}

body.suada-unauthenticated #suadaActionToolbar .btn-icon:hover,
body.suada-unauthenticated #mobileBottomBar .btn-icon:hover {
  opacity: 0.9;
  border-color: rgba(204, 159, 51, 0.45) !important;
}

/* Cacher le badge organisation active si non authentifié */
body.suada-unauthenticated #headerTenantBadge,
body.suada-unauthenticated .tenant-badge {
  display: none !important;
}

/* Cacher le tag Actif du gaufrier pour un visiteur non authentifié */
body.suada-unauthenticated .app-switcher-active-tag,
body.suada-unauthenticated #appSwitcherActiveTag {
  display: none !important;
}

/* Cacher la sous-barre Meeting / Leads si non authentifié */
body.suada-unauthenticated .suada-subnav-bar {
  display: none !important;
}

/* Cacher le cockpit et kanban normaux si non authentifié */
body.suada-unauthenticated #viewRecorderCockpit,
body.suada-unauthenticated #viewProspectionHub {
  display: none !important;
}

/* Afficher obligatoirement le hero si non authentifié */
body.suada-unauthenticated #viewUnauthenticatedHero {
  display: flex !important;
}

/* Responsive Mobile */
@media (max-width: 768px) {
  .unauth-hero-card {
    padding: 30px 20px;
    border-radius: 16px;
  }

  .unauth-title {
    font-size: 1.45rem;
  }

  .unauth-subtitle {
    font-size: 0.88rem;
    margin-bottom: 20px;
  }

  .unauth-features-grid {
    grid-template-columns: 1fr;
    gap: 10px;
    margin-bottom: 24px;
  }

  .btn-unauth-login {
    width: 100%;
    padding: 14px 20px;
    font-size: 0.95rem;
  }

  .unauth-security-footer {
    gap: 10px;
  }
}
