* { box-sizing: border-box; }

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  margin: 0;
  padding: 24px;
  background: #f5f5f7;
  color: #1d1d1f;
  max-width: 1400px;
  margin-left: auto;
  margin-right: auto;
}

header h1 {
  margin: 0 0 8px;
  font-size: 22px;
}

.instructions {
  color: #444;
  font-size: 14px;
  margin: 0 0 12px;
  line-height: 1.45;
}

.annotator-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.annotator-row input {
  padding: 6px 10px;
  border: 1px solid #c7c7cc;
  border-radius: 6px;
  font-size: 14px;
  width: 240px;
}

.name-status {
  font-size: 12px;
  color: #1c8033;
}

.videos {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin-bottom: 12px;
}

figure {
  margin: 0;
  background: #000;
  border-radius: 8px;
  overflow: hidden;
}

figcaption {
  background: #1d1d1f;
  color: #fff;
  text-align: center;
  padding: 6px;
  font-size: 13px;
  letter-spacing: 0.5px;
}

video {
  width: 100%;
  display: block;
  background: #000;
  aspect-ratio: 16 / 9;
}

.controls {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.controls button,
.submit-row button {
  background: #0071e3;
  color: white;
  border: none;
  padding: 8px 16px;
  border-radius: 6px;
  font-size: 14px;
  cursor: pointer;
}

.controls button:hover,
.submit-row button:hover {
  background: #005bb5;
}

button.secondary {
  background: #8e8e93;
}

button.secondary:hover {
  background: #6d6d72;
}

.pair-id {
  margin-left: auto;
  color: #6e6e73;
  font-size: 12px;
  font-family: ui-monospace, SFMono-Regular, monospace;
}

.legend {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 14px;
  background: #eef4ff;
  border: 1px solid #c9dcff;
  border-radius: 8px;
  margin: 8px 0 14px;
}

.legend-illustration svg {
  width: 200px;
  height: 150px;
  display: block;
}

.legend-text {
  font-size: 13px;
  line-height: 1.45;
  color: #333;
}

.legend-text em { color: #0071e3; font-style: normal; font-weight: 500; }
.mark-left { color: #c1272d; font-weight: 600; }

.body-parts {
  border: 1px solid #c7c7cc;
  border-radius: 8px;
  padding: 10px 14px;
  margin: 12px 0;
  background: #fff;
}

.body-parts legend {
  padding: 0 6px;
  font-size: 13px;
  font-weight: 500;
  color: #1d1d1f;
}

.body-parts label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-right: 18px;
  font-size: 14px;
  cursor: pointer;
  user-select: none;
}

.body-parts input[type="checkbox"] {
  width: 16px;
  height: 16px;
  cursor: pointer;
}

.body-parts-note {
  margin: 10px 0 0;
  padding: 8px 10px;
  background: #f7f7fa;
  border-left: 3px solid #0071e3;
  border-radius: 4px;
  font-size: 12.5px;
  line-height: 1.55;
  color: #444;
}

.body-parts-note strong { color: #1d1d1f; }
.body-parts-note em { color: #0071e3; font-style: normal; font-weight: 500; }

.annotation-label {
  display: block;
  font-size: 14px;
  margin-bottom: 6px;
  font-weight: 500;
}

textarea {
  width: 100%;
  padding: 10px;
  border: 1px solid #c7c7cc;
  border-radius: 8px;
  font-size: 14px;
  font-family: inherit;
  resize: vertical;
  background: #fff;
}

textarea:focus {
  outline: 2px solid #0071e3;
  border-color: transparent;
}

.submit-row {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.status {
  font-size: 13px;
  color: #6e6e73;
}

.status.success { color: #1c8033; }
.status.error { color: #c1272d; }
