/**
 * Club-IA — Main front-end styles.
 * Shared layout, typography, utilities.
 */

/* ── Variables ──────────────────────────────────────────────────────────── */
:root {
  --cia-primary:    #2563eb;
  --cia-primary-dk: #1d4ed8;
  --cia-secondary:  #7c3aed;
  --cia-accent:     #06b6d4;
  --cia-success:    #16a34a;
  --cia-warning:    #f59e0b;
  --cia-danger:     #dc2626;
  --cia-bg:         #f8fafc;
  --cia-surface:    #ffffff;
  --cia-border:     #e2e8f0;
  --cia-text:       #1e293b;
  --cia-text-muted: #64748b;
  --cia-radius:     0.5rem;
  --cia-radius-lg:  0.75rem;
  --cia-shadow:     0 1px 3px rgba(0,0,0,.1), 0 1px 2px rgba(0,0,0,.06);
  --cia-shadow-md:  0 4px 6px -1px rgba(0,0,0,.1), 0 2px 4px -2px rgba(0,0,0,.1);
  --cia-transition: 150ms ease;
}

/* ── Wrapper ────────────────────────────────────────────────────────────── */
.club-ia-wrapper {
  max-width: 1200px;
  margin: 0 auto;
  padding: 2rem 1.5rem;
}

/* ── Page Header ────────────────────────────────────────────────────────── */
.club-ia-page-header {
  text-align: center;
  margin-bottom: 2rem;
}
.club-ia-page-header h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--cia-text);
  margin-bottom: 0.5rem;
}
.club-ia-page-subtitle {
  color: var(--cia-text-muted);
  font-size: 1.1rem;
  margin-bottom: 1rem;
}

/* ── Breadcrumb ─────────────────────────────────────────────────────────── */
.club-ia-breadcrumb {
  margin-bottom: 1.5rem;
}
.club-ia-breadcrumb a {
  color: var(--cia-primary);
  text-decoration: none;
  font-weight: 500;
}
.club-ia-breadcrumb a:hover {
  text-decoration: underline;
}

/* ── Badges ─────────────────────────────────────────────────────────────── */
.badge {
  display: inline-block;
  padding: 0.2em 0.6em;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
  line-height: 1.4;
}
.badge--metier       { background: #dbeafe; color: #1e40af; }
.badge--thematique   { background: #ede9fe; color: #5b21b6; }
.badge--outil        { background: #ecfdf5; color: #065f46; }
.badge--level        { background: #fef3c7; color: #92400e; }
.badge--tag          { background: #f1f5f9; color: #475569; }
.level--easy         { background: #dcfce7; color: #166534; }
.level--medium       { background: #fef3c7; color: #92400e; }
.level--hard         { background: #fce7f3; color: #9d174d; }

/* ── Buttons ────────────────────────────────────────────────────────────── */
.btn-primary,
.btn-copy-prompt,
.btn-submit-prompt,
.btn-load-more {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.6rem 1.2rem;
  border: none;
  border-radius: var(--cia-radius);
  font-weight: 600;
  font-size: 0.875rem;
  cursor: pointer;
  transition: background var(--cia-transition), transform var(--cia-transition);
}
.btn-primary,
.btn-submit-prompt {
  background: var(--cia-primary);
  color: #fff;
}
.btn-primary:hover,
.btn-submit-prompt:hover {
  background: var(--cia-primary-dk);
}
.btn-copy-prompt {
  background: var(--cia-success);
  color: #fff;
}
.btn-copy-prompt:hover {
  background: #15803d;
  transform: translateY(-1px);
}
.btn-copy-prompt--copied {
  background: #22c55e !important;
}
.btn-copy-prompt--large {
  padding: 0.8rem 1.8rem;
  font-size: 1rem;
}
.btn-view-prompt {
  display: inline-flex;
  align-items: center;
  padding: 0.6rem 1.2rem;
  border: 1px solid var(--cia-border);
  border-radius: var(--cia-radius);
  font-weight: 500;
  font-size: 0.875rem;
  color: var(--cia-text);
  text-decoration: none;
  transition: border-color var(--cia-transition);
}
.btn-view-prompt:hover {
  border-color: var(--cia-primary);
  color: var(--cia-primary);
}
.btn-secondary {
  background: transparent;
  border: 1px solid var(--cia-border);
  padding: 0.6rem 1.2rem;
  border-radius: var(--cia-radius);
  cursor: pointer;
  font-weight: 500;
}
.btn-load-more {
  background: var(--cia-surface);
  color: var(--cia-primary);
  border: 2px solid var(--cia-primary);
}
.btn-load-more:hover {
  background: var(--cia-primary);
  color: #fff;
}

/* ── No results ─────────────────────────────────────────────────────────── */
.club-ia-no-results {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--cia-text-muted);
  font-size: 1.1rem;
}

/* ── Loading state ──────────────────────────────────────────────────────── */
.loading {
  opacity: 0.5;
  pointer-events: none;
}
.prompt-load-more {
  text-align: center;
  margin: 2rem 0;
}
