* {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  background: #ffffff;
  color: #111111;
  font-family: system-ui, -apple-system, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.page {
  max-width: 780px;
  margin: 36px auto;
  padding: 0 20px;
}

h1 {
  font-family: Georgia, serif;
  font-weight: normal;
  font-size: 30px;
  margin: 0 0 6px;
}

.intro {
  color: #444444;
  margin: 0 0 20px;
  font-size: 15px;
}

.chart-stage {
  position: relative;
}

.scatter-svg {
  display: block;
  width: 100%;
  height: 280px;
  border-bottom: 1px solid #dddddd;
  background: #ffffff;
  overflow: visible;
}

.film-dot {
  cursor: pointer;
  transition: opacity 0.12s ease;
}

.film-dot:hover {
  fill: #1e293b;
  fill-opacity: 1;
}

.floating-tooltip {
  position: absolute;
  pointer-events: none;
  background: #ffffff;
  color: #111111;
  border: 1px solid #bbbbbb;
  padding: 4px 8px;
  font-size: 12px;
  line-height: 1.35;
  white-space: nowrap;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.08);
  z-index: 10;
}

.selected-section {
  margin-top: 18px;
}

.selected-top-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}

.film-summary {
  font-size: 14px;
  color: #222222;
}

.film-select {
  font-family: inherit;
  font-size: 14px;
  padding: 5px 8px;
  border: 1px solid #bbbbbb;
  background: #ffffff;
  color: #111111;
  width: 195px;
  max-width: 100%;
}

.barcode-wrap {
  position: relative;
  margin: 12px 0;
}

.barcode-canvas {
  display: block;
  width: 100%;
  height: 44px;
  border: 1px solid #dddddd;
  cursor: crosshair;
}

.rhythm-row {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: 10px;
  flex-wrap: wrap;
}

.plain-btn {
  font-family: inherit;
  font-size: 14px;
  padding: 7px 12px;
  border: 1px solid #111111;
  background: #ffffff;
  color: #111111;
  cursor: pointer;
}

.plain-btn:hover {
  background: #111111;
  color: #ffffff;
}

.cut-frame {
  width: 120px;
  height: 68px;
  border: 1px solid #111111;
  background: #f8fafc;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: background-color 0.08s ease;
}

.cut-frame.alt-shot {
  background: #eef2f6;
}

.cut-frame.flash {
  background: #ffd8a8;
}

.cut-frame-tag {
  font-size: 12px;
  color: #64748b;
  font-variant-numeric: tabular-nums;
}

.cut-progress {
  position: absolute;
  left: 0;
  bottom: 0;
  height: 3px;
  width: 0%;
  background: #d9480f;
}

.shot-readout {
  font-size: 14px;
  color: #222222;
  font-variant-numeric: tabular-nums;
}

.avg-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 14px;
  color: #444444;
  cursor: pointer;
  user-select: none;
}
