:root {
  --primary-color: #6c5dd3; /* Couleur violette principale */
  --secondary-color: #f7f7f7; /* Gris très clair pour le fond */
  --tertiary-color: #333; /* Gris très clair pour le fond */
  --text-color: #11142d; /* Couleur de texte principale */
  --text-muted: #808191; /* Texte secondaire */
  --border-color: #e4e4e4; /* Couleur des bordures */
  --hover-color: #f8f9fa; /* Couleur de survol */
  --white: #ffffff; /* Blanc */
  --shadow: 0 2px 4px rgba(0, 0, 0, 0.05); /* Ombre douce */
  --badge-bg: #ff754c; /* Couleur badge notifications */
  --success-color: #7fba7a; /* Couleur succès */
}

body {
  font-size: 0.875rem;
  background-color: var(--secondary-color);
  color: var(--text-color);
}

/* Header styles */
.navbar {
  height: 72px;
  background-color: var(--white);
  border-bottom: 1px solid var(--border-color);
  padding: 0 24px;
  margin-bottom: 20px;
  position: fixed;
  top: 0;
  z-index: 1030;
  width: 100%;
  display: flex !important;
  justify-content: space-between;
  align-items: center;

  width: calc(100% - 280px);
}

/* Navbar actions */
.navbar-nav {
  display: flex;
  gap: 8px;
  align-items: center;
  margin-left: auto;
}

.navbar-nav .nav-item {
  position: relative;
}

.navbar-nav .nav-link {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  color: var(--text-muted);
}

.navbar-nav .nav-link:hover {
  background-color: var(--hover-color);
}

.navbar-nav .badge {
  position: absolute;
  top: -4px;
  right: -4px;
  min-width: 20px;
  height: 20px;
  padding: 0 6px;
  border-radius: 20px;
  background-color: var(--badge-bg);
  color: white;
  font-size: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.badge-success {
  background-color: var(--success-color) !important;
}

/* Search box */
.search-box {
  position: relative;
  max-width: 400px;
  width: 100%;
  margin: 0 24px;
}

.search-box input {
  width: 100%;
  height: 40px;
  padding: 8px 40px 8px 16px;
  border: 1px solid var(--border-color);
  border-radius: 8px;
  font-size: 14px;
  color: var(--text-color);
}

.search-box i {
  position: absolute;
  right: 16px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-muted);
}

/* User profile */
.user-profile {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-left: 16px;
  padding: 4px;
  border-radius: 8px;
  cursor: pointer;
}

.user-profile:hover {
  background-color: var(--hover-color);
}

.avatar {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  object-fit: cover;
}

.language-selector {
  display: flex;
  align-items: center;
  gap: 4px;
  padding: 4px 8px;
  background-color: var(--primary-color);
  border-radius: 8px;
  color: white;
}

.language-selector span {
  font-size: 14px;
  font-weight: 500;
}

.language-selector i {
  font-size: 12px;
}

/* Sidebar styles */
.sidebar {
  width: 280px;
  background-color: var(--white);
  border-right: 1px solid var(--border-color);
  height: 100vh;
  position: fixed;
  top: 0;
  left: 0;
  display: flex;
  flex-direction: column;
  padding: 0;
  z-index: 1050;
}

/* Content area adjustments */
.main-content {
  margin-left: 280px;
  min-height: 100vh;
  position: relative;
}

/* Sidebar backdrop for mobile */
.sidebar-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1040;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.sidebar-backdrop.show {
  opacity: 1;
  visibility: visible;
}

/* User section */
.sidebar-user {
  padding: 24px;
  border-top: 1px solid var(--border-color);
}

.user-info {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
}

.user-avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
}

.user-details {
  flex-grow: 1;
}

.user-name {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-color);
}

.user-email {
  font-size: 12px;
  color: var(--text-muted);
}

/* Progress bar */
.progress-section {
  margin-top: 16px;
}

.progress-label {
  font-size: 12px;
  color: var(--text-color);
  font-weight: 500;
}

.progress-count {
  font-size: 12px;
  color: var(--text-muted);
}

.progress {
  height: 16px;
  background-color: #f4f4f4;
  border-radius: 3px;
  margin-top: 8px;
  overflow: hidden;
}

.progress-bar {
  background-color: #ff9f43;
  border-radius: 3px;
}

.progress-bar-0-10 {
  background-color: #ff0000;
}

.progress-bar-10-20 {
  background-color: #ff4000;
}

.progress-bar-20-30 {
  background-color: #ff8000;
}

.progress-bar-30-40 {
  background-color: #ffbf00;
}

.progress-bar-40-50 {
  background-color: #ffff00;
}

.progress-bar-50-60 {
  background-color: #bfff00;
}

.progress-bar-60-70 {
  background-color: #80ff00;
}

.progress-bar-70-80 {
  background-color: #40ff00;
}

.progress-bar-80-90 {
  background-color: #00ff40;
}

.progress-bar-90-100 {
  background-color: #00ff80;
}

/*   Forms   */
#brief,
#plan,
#meta_title,
#meta_description,
#prompt_midjourney,
#prompt_improve {
  font-size: 12px !important;
}

/***********************************/
#highlighted_content {
  background-color: #f8f9fa;
  padding: 1rem;
  border-radius: 0.25rem;
  line-height: 1.5;
  font-family: monospace;
}

#highlighted_content .action {
  font-weight: bold;
  color: #007bff;
  display: inline-block;
}

#highlighted_content .indicateur {
  font-weight: bold;
  margin-right: 0.5rem;
}

#highlighted_content .modification {
  padding: 0.25rem;
  border-radius: 0.25rem;
  margin: 0.25rem 0;
}

/* Styles pour les textareas dans diff-content */
#highlighted_content textarea.diff-delete,
#highlighted_content textarea.diff-add {
  width: 100%;
  min-height: 2rem;
  border: 1px solid rgba(0, 0, 0, 0.1);
  border-radius: 4px;
  resize: vertical;
  font-family: monospace;
  padding: 0.5rem;
  margin-bottom: 0.5rem;
  overflow-x: auto;
  white-space: pre-wrap;
  height: auto;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

#highlighted_content textarea.diff-delete {
  background-color: #ffdddd;
  color: #dc3545;
  border-color: #f5c2c7;
}

#highlighted_content textarea.diff-add {
  background-color: #ddffdd;
  color: #28a745;
  border-color: #a3cfbb;
}

/* Types de diffs */
#highlighted_content .diff-type {
  font-weight: bold;
  margin: 1rem 0 0.5rem 0;
  color: #0d6efd;
  border-bottom: 1px solid #dee2e6;
  padding-bottom: 0.3rem;
}

#highlighted_content .diff-desc {
  font-style: italic;
  margin: 0.5rem 0 1rem 0;
  color: #6c757d;
}

#highlighted_content .diff-title {
  font-size: 1.1rem;
  font-weight: bold;
  margin: 1rem 0;
  color: #212529;
  border-bottom: 1px dashed #dee2e6;
  padding-bottom: 0.3rem;
}

/****************************************/
.ck-content p {
  font-size: 0.9rem;
  margin-bottom: 0.7rem;
}

.ck-content h2 {
  font-size: 1.4rem;
}

.ck-content h3 {
  font-size: 1.2rem;
  color: #0d6efd;
}

.select2-results__option {
  font-size: 11px;
  padding: 3px;
}
/*************************************/
/* Bloc de code */

.code-wrapper {
  position: relative;
}

.relative {
  position: relative;
}

.copy-button {
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  z-index: 10;
  padding: 0.25rem 0.5rem;
  font-size: 0.875rem;
  background-color: rgba(255, 255, 255, 0.1);
  border: 1px solid rgba(255, 255, 255, 0.2);
  border-radius: 0.25rem;
  color: #fff;
  cursor: pointer;
  transition: all 0.2s ease;
}

.copy-button:hover {
  background-color: rgba(255, 255, 255, 0.2);
}

.card {
  border-radius: 8px;
  border: 1px solid rgba(0, 0, 0, 0.125);
}

.card-header {
  background-color: #f8f9fa;
  border-bottom: 1px solid rgba(0, 0, 0, 0.125);
}

.btn {
  border-radius: 6px;
}

.input-group-text {
  min-width: 100px;
  justify-content: center;
}

.form-control:focus {
  border-color: #80bdff;
  box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
}

.shadow-sm {
  box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075) !important;
}

.source-item {
  transition: all 0.3s ease;
}

.source-item:hover {
  transform: translateX(5px);
}

.btn-group {
  gap: 0.5rem;
}

textarea {
  resize: vertical;
}

#links-list input {
  font-size: 10px;
  padding: 2px;
}
#links-list btn {
  padding: 2px !important;
}

.bg-hover-light:hover {
  background-color: #ccc !important;
}

.cursor-pointer {
  cursor: pointer;
}

/* Style pour les séparateurs */
.d-flex.align-items-center h4 {
  color: #495057;
  font-size: 1.25rem;
}

.border-bottom.border-2 {
  border-color: #dee2e6 !important;
}

/*************************************/
/* Responsive */
/*************************************/
@media (max-width: 767.98px) {
  .sidebar {
    top: 5rem;
  }
}

/* Styles pour le bouton de sélection d'amélioration */
#selection-improve-btn {
  animation: fadeIn 0.2s ease-in-out;
  transition: transform 0.2s ease;
}

#selection-improve-btn button {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background-color: var(--primary-color);
  border: none;
  box-shadow: 0 2px 8px rgba(108, 93, 211, 0.4);
}

#selection-improve-btn:hover {
  transform: scale(1.1);
}

#selection-improve-btn button i {
  font-size: 16px;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: scale(0.8);
  }
  to {
    opacity: 1;
    transform: scale(1);
  }
}

/* Modal de sélection d'amélioration */
#improve-selection-modal .modal-header {
  background-color: var(--primary-color);
  color: white;
}

#improve-selection-modal .modal-title {
  font-weight: 600;
}

#selection-text {
  background-color: #f8f9fa;
  border-left: 3px solid var(--primary-color);
}

.card {
  border: none;
  border-radius: 12px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.task-item {
  border-left: 4px solid transparent;
}

.task-item .card-body {
  padding: 1rem;
}

.priority-indicator {
  border-radius: 2px;
}

.timer {
  font-family: "JetBrains Mono", monospace;
  font-size: 1.1rem;
  color: #6c757d;
}

.date-separator {
  position: relative;
  text-align: center;
  margin: 2rem 0;
}

.date-separator::before {
  content: "";
  position: absolute;
  left: 0;
  top: 50%;
  width: 100%;
  height: 1px;
  background: #dee2e6;
  z-index: 1;
}

.date-separator .badge {
  position: relative;
  z-index: 2;
  padding: 0.5rem 1rem;
}

.select2-container--bootstrap-5 .select2-selection {
  border: 1px solid #dee2e6;
  border-radius: 8px;
}

.btn {
  border-radius: 8px;
  padding: 0.5rem 1rem;
}

.btn-sm {
  padding: 0.25rem 0.5rem;
}

.actions .btn {
  width: 32px;
  height: 32px;
  padding: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.task-info .badge {
  padding: 0.5em 0.8em;
  margin-right: 0.5em;
}

.status-badge .badge {
  padding: 0.5em 1em;
  font-weight: 500;
}

/* Styles pour la page de login */
.login-container {
  display: flex;
  min-height: 100vh;
}

.login-image {
  flex: 1;
  background-image: url("/static/img/login-bg.jpg");
  background-size: cover;
  background-position: center;
  position: relative;
  display: none;
}

@media (min-width: 992px) {
  .login-image {
    display: block;
  }
}

.login-image .overlay {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.4);
}

.brand-message {
  position: absolute;
  bottom: 60px;
  left: 60px;
  color: white;
  z-index: 1;
}

.brand-message h1 {
  font-size: 2.5rem;
  font-weight: 700;
  margin-bottom: 1rem;
}

.brand-message p {
  font-size: 1.1rem;
  opacity: 0.9;
}

.login-form {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  background: white;
}

.form-wrapper {
  width: 100%;
  max-width: 420px;
}

.auth-header {
  text-align: center;
  margin-bottom: 2rem;
}

.auth-header h2 {
  font-size: 1.75rem;
  font-weight: 700;
  color: #1a1a1a;
  margin-bottom: 0.5rem;
}

.auth-subtitle {
  color: #666;
  font-size: 0.95rem;
}

.tab-container {
  display: flex;
  margin-bottom: 2rem;
  border-bottom: 2px solid #eee;
}

.tab-btn {
  flex: 1;
  padding: 1rem;
  background: none;
  border: none;
  color: #666;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}

.tab-btn.active {
  color: #007bff;
  border-bottom: 2px solid #007bff;
  margin-bottom: -2px;
}

.login-form .tab-content {
  display: none;
}

.login-form .tab-content.active {
  display: block;
}

.form-group {
  margin-bottom: 1.5rem;
}

.form-group label {
  display: block;
  margin-bottom: 0.5rem;
  color: #444;
  font-weight: 500;
}

.password-input {
  position: relative;
}

.toggle-password {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
}

.social-login {
  margin-top: 2rem;
}

.divider {
  text-align: center;
  margin: 1.5rem 0;
  position: relative;
}

.divider::before,
.divider::after {
  content: "";
  position: absolute;
  top: 50%;
  width: calc(50% - 30px);
  height: 1px;
  background: #ddd;
}

.divider::before {
  left: 0;
}

.divider::after {
  right: 0;
}

.divider span {
  background: white;
  padding: 0 1rem;
  color: #666;
  font-size: 0.9rem;
}

.btn-google {
  background: white;
  border: 1px solid #ddd;
  color: #444;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: all 0.3s;
}

.btn-google:hover {
  background: #f8f9fa;
}

.btn-google img {
  width: 18px;
  height: 18px;
}

/* Sidebar toggle styles */
.content {
  margin-left: 280px;
  transition: margin-left 0.3s ease;
}

.content.expanded {
  margin-left: 70px;
}

/* Animation du bouton toggle */
#sidebar-toggle {
  transition: transform 0.3s ease;
}

.sidebar-collapsed #sidebar-toggle {
  transform: rotate(180deg);
}

/* Logout section */
.logout-section {
  padding: 24px 16px;
  border-top: 1px solid var(--border-color);
}

.logout-button {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-color);
  text-decoration: none;
  padding: 12px;
  border-radius: 8px;
  transition: background-color 0.3s ease;
}

.logout-button:hover {
  background-color: var(--hover-color);
}

.logout-button i {
  font-size: 1.2rem;
  color: var(--text-muted);
}

/* Styles pour la page de compte */
#account-form .form-label {
  font-weight: 500;
  color: #343a40;
}

#account-form .form-control {
  border-radius: 0.25rem;
}

#account-form .btn-primary {
  background-color: #6c5dd3;
  border-color: #6c5dd3;
}

#account-form .btn-primary:hover {
  background-color: #5a49c7;
  border-color: #5a49c7;
}

/* Account page styles */
.shadow-soft {
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04) !important;
}

.avatar-wrapper {
  display: inline-block;
}

.avatar-preview {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.avatar-preview:hover {
  transform: scale(1.05);
}

.form-control-modern {
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  font-size: 0.9rem;
  transition: all 0.2s ease;
}

.form-control-modern:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 3px rgba(108, 93, 211, 0.1);
}

.form-label {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-color);
  margin-bottom: 0.5rem;
}

.btn-primary {
  background-color: var(--primary-color) !important;
  border-color: var(--primary-color) !important;
}

#account-form .btn-primary {
  background-color: var(--primary-color);
  border: none;
  padding: 0.75rem 1.5rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

#account-form .btn-primary:hover {
  background-color: darken(var(--primary-color), 5%);
  transform: translateY(-1px);
}

.btn-outline-primary {
  color: var(--primary-color);
  border-color: var(--primary-color);
  background-color: transparent;
  transition: all 0.2s ease;
}

.btn-outline-primary:hover {
  background-color: var(--primary-color);
  color: white;
}

/* Styles pour les logos des sites */
.logo-cell {
  width: 50px;
  height: 50px;
  position: relative;
}

.logo-cell:empty::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 24px;
  height: 24px;
  background-image: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="none" stroke="%23808191" stroke-width="2" stroke-linecap="round" stroke-linejoin="round"><rect x="3" y="3" width="18" height="18" rx="2" ry="2"></rect><circle cx="8.5" cy="8.5" r="1.5"></circle><polyline points="21 15 16 10 5 21"></polyline></svg>');
  opacity: 0.5;
}

.site-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  border-radius: 4px;
  padding: 2px;
  background: white;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
}

/* Styles pour le select d'amélioration */
#improvement-type {
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
  padding: 0.5rem;
  width: 100%;
  font-size: 1rem;
  transition: border-color 0.2s ease-in-out, box-shadow 0.2s ease-in-out;
  background-color: #fff;
  height: 40px;
}

#improvement-type:focus {
  border-color: #4b94e4;
  box-shadow: 0 0 0 0.25rem rgba(75, 148, 228, 0.25);
  outline: 0;
}

/* Styles pour les options du select */
#improvement-type option {
  padding: 8px;
}

#improvement-type option:first-child {
  font-style: italic;
  color: #6c757d;
}

/* Style pour le textarea des instructions */
#selection-prompt {
  border: 1px solid #ced4da;
  border-radius: 0.25rem;
  padding: 0.75rem;
  width: 100%;
  font-size: 1rem;
  transition: all 0.3s ease;
  min-height: 120px;
  resize: vertical;
  background-color: rgba(248, 249, 250, 0.5);
}

#selection-prompt:focus {
  border-color: #4b94e4;
  box-shadow: 0 0 0 0.25rem rgba(75, 148, 228, 0.25);
  outline: 0;
  background-color: #fff;
}

/* Style pour le textarea quand il contient du texte */
#selection-prompt.with-content {
  background-color: #fff;
  border-left: 3px solid #4b94e4;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Animation pour le changement d'état */
@keyframes highlight-field {
  0% {
    background-color: rgba(75, 148, 228, 0.1);
  }
  50% {
    background-color: rgba(75, 148, 228, 0.2);
  }
  100% {
    background-color: #fff;
  }
}

.with-content {
  animation: highlight-field 0.5s ease-out;
}

/* Style pour étiquettes de formulaire */
.form-label {
  font-weight: 500;
  margin-bottom: 0.5rem;
  color: #495057;
}

/* Style pour les tips sous les champs */
.form-text {
  color: #6c757d;
  font-size: 0.875rem;
  margin-top: 0.25rem;
}

/* Style pour le modal d'amélioration de texte */
#improve-selection-modal .modal-content {
  border: none;
  box-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.15);
  border-radius: 0.5rem;
}

#improve-selection-modal .modal-header {
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
  background-color: #f8f9fa;
  border-radius: 0.5rem 0.5rem 0 0;
}

#improve-selection-modal .modal-footer {
  border-top: 1px solid rgba(0, 0, 0, 0.1);
  background-color: #f8f9fa;
  border-radius: 0 0 0.5rem 0.5rem;
}

/* Animation de la modale */
.modal.fade .modal-dialog {
  transition: transform 0.3s ease-out;
  transform: scale(0.95);
}

.modal.show .modal-dialog {
  transform: scale(1);
}

/* Styles responsifs pour la modale */
@media (min-width: 576px) {
  #improve-selection-modal .modal-dialog {
    max-width: 500px;
  }
}

@media (min-width: 768px) {
  #improve-selection-modal .modal-dialog {
    max-width: 600px;
  }
}

/* Styles pour le bouton de copie HTML */
#copy-html-btn {
  z-index: 100;
  font-size: 0.85rem;
  padding: 0.3rem 0.8rem;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  transition: all 0.2s ease;
}

#copy-html-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

#copy-html-btn i {
  margin-right: 5px;
}

/* Styles pour améliorer l'apparence des blocs pre et code dans CKEditor */
.ck-content pre {
  background-color: #f5f5f5;
  border: 1px solid #e0e0e0;
  border-radius: 4px;
  padding: 16px;
  margin: 16px 0;
  overflow-x: auto;
  white-space: pre !important;
  tab-size: 4;
  -moz-tab-size: 4;
  font-family: "Consolas", "Monaco", "Courier New", monospace;
  font-size: 0.9rem;
  line-height: 1.5;
  color: #333;
}

/* Conservation des sauts de ligne dans les balises code */
.ck-content pre code {
  white-space: pre !important;
  display: block;
  word-wrap: normal;
  overflow-wrap: normal;
  background-color: transparent;
  border: none;
  padding: 0;
  font-family: inherit;
  color: inherit;
}

/* Style spécifique pour préserver les sauts de ligne dans l'éditeur source */
.ck-source-editing-area textarea {
  white-space: pre !important;
  font-family: "Consolas", "Monaco", "Courier New", monospace !important;
  font-size: 14px !important;
  line-height: 1.6 !important;
  tab-size: 4 !important;
  -moz-tab-size: 4 !important;
}

/* Coloration syntaxique basique pour les langages courants */
.ck-content pre.language-javascript,
.ck-content pre.language-js {
  border-left: 4px solid #f7df1e;
}

.ck-content pre.language-html,
.ck-content pre.language-xml {
  border-left: 4px solid #e34c26;
}

.ck-content pre.language-css {
  border-left: 4px solid #264de4;
}

.ck-content pre.language-php {
  border-left: 4px solid #8892bf;
}

.ck-content pre.language-python {
  border-left: 4px solid #3572a5;
}

.ck-content pre.language-sql {
  border-left: 4px solid #f29111;
}

.ck-content pre.language-bash,
.ck-content pre.language-shell {
  border-left: 4px solid #4eaa25;
}

/* Styles pour les éléments spécifiques dans le code */
.ck-content pre .keyword,
.ck-content code .keyword {
  color: #0000ff;
}

.ck-content pre .string,
.ck-content code .string {
  color: #a31515;
}

.ck-content pre .comment,
.ck-content code .comment {
  color: #008000;
}

.ck-content pre .function,
.ck-content code .function {
  color: #795e26;
}

/* Assurer que l'éditeur source préserve bien les espaces et les sauts de ligne */
.ck.ck-editor__editable_inline {
  white-space: pre-wrap !important;
}

/* Styles pour le système d'étapes en ronds */
.steps-container {
  margin-bottom: 2rem;
}

.steps {
  position: relative;
  display: flex;
  align-items: center;
  width: 100%;
}

.step-item {
  position: relative;
  text-align: center;
  min-width: 80px;
  z-index: 2;
  cursor: pointer;
}

.step-circle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background-color: #f5f5f5;
  border: 2px solid #ddd;
  color: #666;
  font-weight: bold;
  margin: 0 auto 8px;
  transition: all 0.3s ease;
}

.step-title {
  font-size: 12px;
  font-weight: 500;
  color: #666;
  transition: all 0.3s ease;
}

.step-line {
  height: 3px;
  background-color: #ddd;
  z-index: 1;
  margin: 0 10px;
  margin-bottom: 35px;
}

/* État actif */
.step-item.active .step-circle {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
  color: white;
  transform: scale(1.1);
  box-shadow: 0 0 0 4px rgba(108, 93, 211, 0.2);
}

.step-item.active .step-title {
  color: var(--primary-color);
  font-weight: 600;
}

/* État complété */
.step-item.completed .step-circle {
  background-color: var(--success-color);
  border-color: var(--success-color);
  color: white;
}

.step-item.completed .step-title {
  color: var(--success-color);
}

/* Animation de transition entre les étapes */
.step-content {
  display: none;
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.3s ease, transform 0.3s ease;
}

.step-content.active {
  display: block;
  opacity: 1;
  transform: translateY(0);
}

/* Animation au survol des étapes */
.step-item:not(.active):hover .step-circle {
  transform: scale(1.05);
  border-color: #aaa;
  background-color: #f0f0f0;
}

.step-item:not(.active):hover .step-title {
  color: #333;
}

/* Styles pour la recherche */
#header-search-form {
  display: flex;
  align-items: center;
  width: 100%;
}

#header-search-input {
  width: 100%;
  padding-right: 35px;
}

#header-search-submit {
  position: absolute;
  right: 10px;
  cursor: pointer;
}

/* Styles pour les résultats de recherche */
.search-result-item {
  transition: all 0.2s ease;
  border-left: 3px solid transparent;
}

.search-result-item:hover {
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
  transform: translateY(-2px);
}

.search-result-item[data-type="content"] {
  border-left-color: #007bff;
}

.search-result-item[data-type="site"] {
  border-left-color: #28a745;
}

/* Style pour surligner les termes recherchés */
.highlight-search-term {
  background-color: #fff3cd;
  padding: 0 2px;
  border-radius: 3px;
}

/* Animation pour les résultats de recherche */
@keyframes fadeInResult {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.search-result-item {
  animation: fadeInResult 0.3s ease forwards;
}

/* Styles pour le formulaire de recherche principal */
#searchInput {
  border-radius: 4px 0 0 4px;
  font-size: 1rem;
  padding: 12px 15px;
}

.results-container .badge {
  font-weight: normal;
  padding: 6px 10px;
}

/* ===========================================
   SIDEBAR RESPONSIVE IMPROVEMENTS
   =========================================== */

/* Mobile header */
.mobile-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: 60px;
  background: var(--white);
  border-bottom: 1px solid var(--border-color);
  z-index: 1060;
  padding: 0 15px;
  display: none;
  align-items: center;
  justify-content: space-between;
}

.mobile-header .logo {
  display: flex;
  align-items: center;
  gap: 12px;
  flex: none; /* Prend seulement l'espace nécessaire */
}

.mobile-header .logo img {
  width: 32px;
  height: 32px;
}

.mobile-header .logo-text {
  font-size: 18px;
  font-weight: 600;
  color: var(--text-color);
}

.mobile-menu-toggle {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  background: var(--primary-color);
  border: none;
  border-radius: 8px;
  color: white;
  font-size: 18px;
  transition: all 0.3s ease;
  margin-left: auto; /* Force le bouton à droite */
}

.mobile-menu-toggle:hover {
  background-color: darken(var(--primary-color), 10%);
  transform: scale(1.05);
}

/* Content area adjustments */
.main-content {
  margin-left: 280px;
  min-height: 100vh;
  position: relative;
}

/* Sidebar backdrop for mobile */
.sidebar-backdrop {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 1040;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.3s ease, visibility 0.3s ease;
}

.sidebar-backdrop.show {
  opacity: 1;
  visibility: visible;
}

/* Desktop toggle button */
.sidebar-toggle {
  position: absolute;
  top: 20px;
  right: -15px;
  width: 30px;
  height: 30px;
  background: var(--white);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 12px;
  color: var(--text-muted);
  transition: all 0.3s ease;
  z-index: 10;
}

.sidebar-toggle:hover {
  background: var(--primary-color);
  color: white;
  border-color: var(--primary-color);
}

.sidebar.mini .sidebar-toggle i {
  transform: rotate(180deg);
}

/* Header adjustments for different sidebar states */

/* Main content adjustment for fixed header */
main {
  padding-top: 10px; /* Height of navbar + margin */
}

/* ===========================================
   MOBILE RESPONSIVE
   =========================================== */

@media (max-width: 768px) {
  /* Show mobile header */
  .mobile-header {
    display: flex;
  }

  /* Adjust navbar for mobile */
  .navbar {
    margin-left: 0;
    width: 100%;
    top: 60px; /* Sous le mobile header */
    height: 50px;
    padding: 0 15px;
  }

  .navbar-page-title h1 {
    font-size: 18px;
  }

  /* Adjust main content */
  .main-content {
    margin-left: 0;
    padding-top: 110px; /* 60px mobile header + 50px navbar */
  }

  main {
    padding-top: 20px;
  }

  /* Sidebar mobile behavior */
  .sidebar {
    left: -100%;
    transition: left 0.3s ease;
  }

  .sidebar.show {
    left: 0;
  }

  /* Mobile-specific adjustments */
  .sidebar-logo {
    padding: 20px;
  }

  .sidebar-menu {
    padding: 20px 16px;
  }

  .sidebar-user {
    padding: 20px;
  }
}

@media (max-width: 576px) {
  .container-fluid {
    padding-left: 10px;
    padding-right: 10px;
  }

  .mobile-header {
    padding: 0 10px;
  }

  .mobile-header .logo-text {
    font-size: 16px;
  }

  .dashboard-card {
    margin-bottom: 16px;
  }

  .stat-card {
    padding: 16px;
    margin-bottom: 16px;
  }

  .btn {
    padding: 10px 20px;
    font-size: 14px;
  }
}

/* ===========================================
   SIDEBAR NAVIGATION IMPROVEMENTS
   =========================================== */

/* Better spacing and hover effects */
.nav-item {
  margin-bottom: 2px;
}

.nav-link {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  color: var(--text-muted);
  border-radius: 8px;
  transition: all 0.2s ease;
  position: relative;
  text-decoration: none;
}

.nav-link i {
  width: 20px;
  font-size: 16px;
  margin-right: 12px;
  text-align: center;
}

.nav-link span {
  flex-grow: 1;
  font-size: 14px;
  font-weight: 500;
}

.nav-link:hover {
  background-color: var(--hover-color);
  color: var(--text-color);
  transform: translateX(2px);
}

.nav-link.active {
  background-color: var(--primary-color);
  color: var(--white);
  box-shadow: 0 2px 4px rgba(108, 93, 211, 0.2);
}

.nav-link.active::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  width: 3px;
  background: rgba(255, 255, 255, 0.8);
  border-radius: 0 3px 3px 0;
}

/* Sous-menus */
.parent-menu-item {
  position: relative;
}

.parent-menu-item > .nav-link {
  position: relative;
}

.sub-menu-arrow {
  margin-left: auto !important;
  font-size: 12px !important;
  transition: transform 0.3s ease;
  width: auto !important;
}

.parent-menu-item.active .sub-menu-arrow {
  transform: rotate(180deg);
}

.sub-menu {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease, opacity 0.3s ease;
  opacity: 0;
  margin-left: 20px;
  border-left: 2px solid var(--border-color);
  padding-left: 16px;
}

.sub-menu.show {
  max-height: 500px;
  opacity: 1;
}

.sub-menu .nav-link {
  padding: 8px 12px;
  font-size: 13px;
  border-radius: 6px;
}

.sub-menu .nav-link:hover {
  background-color: var(--hover-color);
  transform: translateX(4px);
}

.sub-menu .nav-link.active {
  background-color: rgba(108, 93, 211, 0.1);
  color: var(--primary-color);
  border-left: 2px solid var(--primary-color);
}

/* Badge improvements */
.badge-count {
  background-color: #4cd964;
  color: var(--white);
  font-size: 11px;
  padding: 2px 6px;
  border-radius: 10px;
  margin-left: auto;
  min-width: 18px;
  text-align: center;
}

.badge-count.yellow {
  background-color: #ffb800;
}

.badge-count.red {
  background-color: #ff3b30;
}

/* Menu headers */
.menu-header {
  color: var(--text-muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 12px;
  margin-top: 24px;
  padding-left: 16px;
  font-weight: 600;
}

.menu-header:first-child {
  margin-top: 0;
}

/* ===========================================
   ACCOUNT BUTTON IMPROVEMENTS
   =========================================== */

.account-section {
  margin-top: 16px;
}

.account-button {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text-color);
  text-decoration: none;
  padding: 12px;
  border-radius: 8px;
  transition: background-color 0.3s ease;
  border: 1px solid var(--border-color);
}

.account-button:hover {
  background-color: var(--hover-color);
  text-decoration: none;
  color: var(--text-color);
}

.account-button i {
  font-size: 16px;
  color: var(--text-muted);
}

/* ===========================================
   PASSWORD INPUT IMPROVEMENTS
   =========================================== */

.password-input {
  position: relative;
}

.password-input input {
  padding-right: 45px;
}

.password-input .toggle-password {
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  border: none;
  background: none;
  color: var(--text-muted);
  cursor: pointer;
  padding: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border-radius: 4px;
  transition: all 0.2s ease;
}

.password-input .toggle-password:hover {
  background-color: var(--hover-color);
  color: var(--text-color);
}

/* ===========================================
   FORM IMPROVEMENTS
   =========================================== */

.form-check {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  margin-bottom: 0;
}

.form-check-input {
  margin-top: 2px;
  width: 18px;
  height: 18px;
  border: 2px solid var(--border-color);
  border-radius: 4px;
  transition: all 0.2s ease;
}

.form-check-input:checked {
  background-color: var(--primary-color);
  border-color: var(--primary-color);
}

.form-check-input:focus {
  border-color: var(--primary-color);
  box-shadow: 0 0 0 0.2rem rgba(108, 93, 211, 0.15);
}

.form-check-label {
  font-size: 14px;
  color: var(--text-color);
  line-height: 1.4;
  cursor: pointer;
}

/* ===========================================
   UTILITY CLASSES FOR RESPONSIVE
   =========================================== */

.d-mobile-none {
  display: block;
}

.d-mobile-block {
  display: none;
}

@media (max-width: 768px) {
  .d-mobile-none {
    display: none;
  }

  .d-mobile-block {
    display: block;
  }

  /* Force mobile header to be flex on mobile */
  .mobile-header.d-mobile-block {
    display: flex !important;
  }
}

/* Logo section */
.sidebar-logo {
  padding: 24px;
  border-bottom: 1px solid var(--border-color);
  text-align: center;
  background: linear-gradient(135deg, #f8f9fa 0%, #ffffff 100%);
}

.sidebar-logo a {
  text-decoration: none;
  display: flex;
  flex-direction: column;
  align-items: center;
}

.logo-icon {
  width: 40px;
  height: 40px;
  margin-bottom: 8px;
}

.logo-text {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-color);
  margin-bottom: 4px;
  letter-spacing: -0.5px;
}

.logo-subtitle {
  color: var(--text-muted);
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  font-weight: 500;
  display: inline-block;
}

/* Menu section */
.sidebar-menu {
  padding: 24px 16px;
  flex-grow: 1;
  overflow-y: auto;
}

.menu-header {
  color: var(--text-muted);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
  padding-left: 12px;
}

.nav-item {
  margin-bottom: 4px;
}

.nav-link {
  display: flex;
  align-items: center;
  padding: 12px 16px;
  color: var(--text-muted);
  border-radius: 12px;
  transition: all 0.2s ease;
}

.nav-link i {
  width: 20px;
  font-size: 18px;
  margin-right: 12px;
}

.nav-link span {
  flex-grow: 1;
  font-size: 14px;
  font-weight: 500;
}

.nav-link:hover {
  background-color: var(--hover-color);
  color: var(--text-color);
}

.nav-link.active {
  background-color: var(--primary-color);
  color: var(--white);
}

.badge-count {
  background-color: #4cd964;
  color: var(--white);
  font-size: 12px;
  padding: 2px 8px;
  border-radius: 20px;
  margin-left: 8px;
}

.badge-count.yellow {
  background-color: #ffb800;
}

.navbar-page-title {
  display: flex;
  align-items: center;
  gap: 16px;
}

.navbar-page-title h1 {
  font-size: 24px;
  font-weight: 600;
  color: var(--text-color);
  margin: 0;
}
