* { margin: 0; padding: 0; box-sizing: border-box; }

body {
  font-family: 'Segoe UI', Arial, sans-serif;
  background: #ffffff;
  color: #0a0a0a;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
}

.container {
  background: #ffffff;
  border: 1px solid #e0e0e0;
  border-top: 4px solid #cc0000;
  padding: 2rem;
  max-width: 700px;
  width: 90%;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

h1 {
  font-size: 1.5rem;
  font-weight: 700;
  color: #0a0a0a;
  margin-bottom: 0.3rem;
}

h1 span {
  color: #cc0000;
}

.subtitle {
  color: #555555;
  font-size: 0.88rem;
  margin-bottom: 1.5rem;
  line-height: 1.5;
  border-bottom: 1px solid #e0e0e0;
  padding-bottom: 1rem;
}

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

label {
  display: block;
  color: #333333;
  font-size: 0.82rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 0.4rem;
}

input, select {
  width: 100%;
  padding: 0.6rem 0.8rem;
  background: #fafafa;
  border: 1px solid #d0d0d0;
  border-radius: 0;
  color: #0a0a0a;
  font-size: 0.95rem;
  font-family: 'Segoe UI', Arial, sans-serif;
  outline: none;
  transition: border-color 0.15s;
}

input:focus, select:focus {
  border-color: #cc0000;
  background: #ffffff;
}

button {
  width: 100%;
  padding: 0.85rem;
  background: #cc0000;
  color: #ffffff;
  border: none;
  border-radius: 0;
  font-size: 0.95rem;
  font-family: 'Segoe UI', Arial, sans-serif;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  cursor: pointer;
  margin-top: 1rem;
  transition: background 0.2s;
}

button:hover { background: #8b0000; }

button:disabled {
  background: #cccccc;
  color: #888888;
  cursor: not-allowed;
}

/* ── Messages de statut ──────────────────────────────────── */
.status {
  margin-top: 1rem;
  padding: 1rem 1.2rem;
  font-size: 0.9rem;
  line-height: 1.7;
  display: none;
  border-left: 4px solid transparent;
}

.status.success {
  display: block;
  background: #fafafa;
  border-left-color: #cc0000;
  color: #0a0a0a;
}

.status.error {
  display: block;
  background: #fafafa;
  border-left-color: #8b0000;
  color: #8b0000;
}

.status.loading {
  display: block;
  background: #fafafa;
  border-left-color: #999999;
  color: #555555;
}

/* Message Big Brother — fond noir */
.status.warning {
  display: block;
  background: #0a0a0a;
  border-left-color: #cc0000;
  color: #ffffff;
  line-height: 1.8;
}

.status.warning strong {
  color: #ffffff;
  font-weight: 700;
}

.status code {
  font-family: 'Courier New', monospace;
  font-size: 0.82rem;
  background: rgba(204, 0, 0, 0.08);
  padding: 1px 5px;
  color: #cc0000;
}

.status.warning code {
  background: rgba(255, 255, 255, 0.1);
  color: #ffffff;
}

.bb-headline {
  font-size: 1.2rem;
  font-weight: 700;
  color: #cc0000;
  margin-bottom: 0.8rem;
  letter-spacing: 0.01em;
}

.bb-detail {
  font-size: 0.80rem;
  color: rgba(255, 255, 255, 0.55);
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  line-height: 1.6;
}

/* ── Tableau des signaux ─────────────────────────────────── */
.signals {
  margin-top: 1.5rem;
  border-top: 2px solid #0a0a0a;
  padding-top: 1rem;
  display: none;
}

.signals h3 {
  color: #0a0a0a;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.8rem;
}

.signal-item {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  padding: 0.45rem 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.84rem;
  gap: 1rem;
}

.signal-item:last-child {
  border-bottom: none;
}

.signal-name {
  color: #555555;
  min-width: 170px;
  flex-shrink: 0;
  font-size: 0.82rem;
}

.signal-value {
  color: #0a0a0a;
  max-width: 60%;
  text-align: right;
  word-break: break-all;
  font-family: 'Courier New', monospace;
  font-size: 0.80rem;
}

.signal-value.collecting { color: #999999; font-style: italic; }
.signal-value.done       { color: #cc0000; }
.signal-value.error      { color: #8b0000; }

canvas { display: none; }