/* TechBase - Styles personnalisés minimaux */

/* Variables de couleurs pour compatibilité */
:root {
  --primary: #0d9488;
  --primary-dark: #0f766e;
  --danger: #dc2626;
  --warning: #d97706;
  --success: #16a34a;
  --info: #1e40af;
}

/* Header de page sticky */
.page-header-sticky {
  position: sticky;
  top: 0;
  z-index: 10;
  background: #f9fafb;
  padding-bottom: 1rem;
  margin-bottom: 1.5rem;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

/* Créer un espace opaque au-dessus du header pour masquer le contenu qui scroll */
.page-header-sticky::before {
  content: '';
  position: absolute;
  top: -2rem;
  left: -2rem;
  right: -2rem;
  height: 2rem;
  background: #f9fafb;
  z-index: -1;
}

@media (min-width: 768px) {
  .page-header-sticky::before {
    top: -3rem;
    height: 3rem;
  }
}

@media (min-width: 1024px) {
  .page-header-sticky::before {
    top: -4rem;
    height: 4rem;
  }
}

/* Style pour le contenu Markdown/HTML des fiches */
.content-text {
  line-height: 1.7;
}

.content-text h1 {
  font-size: 2rem;
  font-weight: 700;
  margin: 2rem 0 1rem 0;
  border-bottom: 2px solid var(--primary);
  padding-bottom: 0.5rem;
}

.content-text h2 {
  font-size: 1.5rem;
  font-weight: 700;
  margin: 1.5rem 0 0.75rem 0;
  border-left: 4px solid var(--primary);
  padding-left: 0.75rem;
}

.content-text h3 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 1.25rem 0 0.5rem 0;
}

.content-text p {
  margin-bottom: 1rem;
}

.content-text ul, .content-text ol {
  margin-left: 1.5rem;
  margin-bottom: 1rem;
}

.content-text li {
  margin-bottom: 0.5rem;
}

.content-text code {
  background: #f3f4f6;
  padding: 0.2rem 0.4rem;
  border-radius: 4px;
  font-family: 'Courier New', monospace;
  font-size: 0.875rem;
  color: var(--primary);
}

.content-text pre {
  background: #f3f4f6;
  border-left: 4px solid var(--primary);
  padding: 1rem;
  border-radius: 6px;
  overflow-x: auto;
  margin-bottom: 1rem;
}

.content-text pre code {
  background: none;
  padding: 0;
}

.content-text blockquote {
  border-left: 4px solid var(--primary);
  background: #f0fdfa;
  padding: 0.75rem 1rem;
  margin: 1rem 0;
  border-radius: 4px;
}

.content-text table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1rem;
}

.content-text th, .content-text td {
  border: 1px solid #e5e7eb;
  padding: 0.5rem 0.75rem;
  text-align: left;
}

.content-text th {
  background: #f3f4f6;
  font-weight: 600;
}

.content-text img {
  max-width: 100%;
  border-radius: 6px;
  margin: 1rem 0;
}

.content-text a {
  color: var(--primary);
  text-decoration: underline;
}

.content-text a:hover {
  color: var(--primary-dark);
}
