/**
 * Lorentz Transformation Visualizer — Minkowski spacetime
 * Scoped styles for #lorentz-tutorial. Dark mode, neon axes (S blue, S' orange).
 */
#lorentz-tutorial {
  max-width: 800px;
  font-family: 'Courier New', Courier, monospace;
  background: #0a0a0c;
  color: #e0e0e0;
  padding: 16px;
  border: 1px solid #333;
  border-radius: 8px;
  box-sizing: border-box;
}

#lorentz-tutorial * {
  box-sizing: border-box;
}

/* Control panel: sections and rows */
#lorentz-tutorial .lorentz-control-panel {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 14px 24px;
  margin-bottom: 14px;
  padding: 14px;
  background: #16161a;
  border: 1px solid #333;
  border-radius: 6px;
}

#lorentz-tutorial .lorentz-control-section {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

#lorentz-tutorial .lorentz-section-title {
  font-size: 10px;
  font-weight: bold;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #888;
  margin-bottom: 2px;
}

#lorentz-tutorial .lorentz-control-row {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

#lorentz-tutorial .lorentz-control-row label {
  font-size: 13px;
  color: #fff;
  white-space: nowrap;
}

#lorentz-tutorial .lorentz-control-row input[type="range"] {
  width: 140px;
  cursor: pointer;
}

#lorentz-tutorial .lorentz-control-row .lorentz-val {
  font-family: 'Courier New', monospace;
  font-size: 12px;
  color: #00d4ff;
  min-width: 52px;
}

#lorentz-tutorial .lorentz-val-label {
  font-size: 12px;
  color: #888;
  margin-left: 8px;
}

#lorentz-tutorial .lorentz-check-label {
  font-size: 13px;
}

#lorentz-tutorial .lorentz-hint {
  font-size: 11px;
  color: #888;
}

#lorentz-tutorial .lorentz-btn {
  padding: 8px 14px;
  font-family: 'Courier New', monospace;
  font-size: 12px;
  background: #0a0a0c;
  border: 1px solid #ff9f00;
  color: #e0e0e0;
  border-radius: 4px;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

#lorentz-tutorial .lorentz-btn:hover {
  background: #ff9f00;
  color: #0a0a0c;
}

#lorentz-tutorial .lorentz-sync-btn {
  border-color: #00ff66;
  color: #00ff66;
}

#lorentz-tutorial .lorentz-sync-btn:hover {
  background: #00ff66;
  color: #0a0a0c;
}

/* View mode label */
#lorentz-tutorial .lorentz-view-label {
  font-size: 13px;
  color: #fff;
  margin-right: 4px;
}

#lorentz-tutorial .lorentz-control-row input[type="radio"] {
  cursor: pointer;
}

/* Viewport and canvas */
#lorentz-tutorial .lorentz-viewport-wrap {
  width: 100%;
  max-width: 800px;
}

#lorentz-tutorial .lorentz-viewport {
  position: relative;
  width: 100%;
  max-width: 800px;
  background: #0a0a0c;
  border: 1px solid #333;
  border-radius: 6px;
  overflow: hidden;
}

#lorentz-tutorial #lorentz-canvas,
#lorentz-tutorial #lorentz-canvas-time,
#lorentz-tutorial #lorentz-canvas-space {
  display: block;
  width: 100%;
  cursor: crosshair;
}

/* Split-screen: Time Dilation | Length Contraction */
#lorentz-tutorial .lorentz-split-container {
  display: flex;
  gap: 10px;
  width: 100%;
  max-width: 800px;
  min-height: 400px;
  margin-top: 0;
}

#lorentz-tutorial .lorentz-viewport-split {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  background: #0a0a0c;
  border: 1px solid #333;
  border-radius: 6px;
  overflow: hidden;
}

#lorentz-tutorial .lorentz-split-label {
  font-size: 12px;
  font-weight: bold;
  color: #e0e0e0;
  padding: 8px 10px;
  background: #16161a;
  border-bottom: 1px solid #333;
  font-family: 'Courier New', monospace;
}

#lorentz-tutorial .lorentz-viewport-split canvas {
  flex: 1;
  min-height: 280px;
}

#lorentz-tutorial .lorentz-split-caption {
  font-size: 10px;
  color: #888;
  padding: 6px 10px;
  background: #0e0e10;
  border-top: 1px solid #222;
  font-family: 'Courier New', monospace;
  line-height: 1.35;
}

/* Legend */
#lorentz-tutorial .lorentz-legend {
  position: absolute;
  bottom: 12px;
  right: 12px;
  background: rgba(0, 0, 0, 0.8);
  padding: 8px 12px;
  border-radius: 4px;
  font-size: 11px;
  font-family: 'Courier New', monospace;
}

#lorentz-tutorial .lorentz-legend span.lorentz-s {
  color: #00d4ff;
}

#lorentz-tutorial .lorentz-legend span.lorentz-sprime {
  color: #ff9f00;
}

#lorentz-tutorial .lorentz-legend span.lorentz-light {
  color: rgba(255, 255, 255, 0.7);
}

#lorentz-tutorial .lorentz-legend span.lorentz-twin {
  color: #ff3366;
}

#lorentz-tutorial .lorentz-control-row input[type="checkbox"] {
  cursor: pointer;
}

/* Info panel wrapper — scale toggle on top */
#lorentz-tutorial .lorentz-info-panel {
  width: 100%;
  box-sizing: border-box;
}

#lorentz-tutorial .lorentz-matrix-container .lorentz-scale-toggle {
  margin-bottom: 12px;
  padding: 10px 14px;
  background: #16161a;
  border: 1px solid #333;
  border-radius: 6px;
}

/* Formula / info box — full width */
#lorentz-tutorial .lorentz-formula-box {
  margin-bottom: 12px;
  padding: 12px;
  width: 100%;
  background: #16161a;
  border: 1px solid #333;
  border-radius: 6px;
  font-size: 13px;
  box-sizing: border-box;
}

#lorentz-tutorial .lorentz-formula-title {
  font-weight: bold;
  color: #ff9f00;
  margin-bottom: 8px;
}

#lorentz-tutorial .lorentz-formula-table {
  width: 100%;
  border-collapse: collapse;
  font-family: 'Courier New', monospace;
}

#lorentz-tutorial .lorentz-formula-table th,
#lorentz-tutorial .lorentz-formula-table td {
  padding: 6px 10px;
  text-align: left;
  border-bottom: 1px solid #333;
}

#lorentz-tutorial .lorentz-formula-table th {
  color: #fff;
  font-weight: normal;
  font-size: 13px;
  text-transform: uppercase;
}

#lorentz-tutorial .lorentz-formula-table td {
  color: #fff;
}

#lorentz-tutorial .lorentz-plug {
  color: #00d4ff;
}

#lorentz-tutorial .lorentz-formula-table td span {
  color: #ff9f00;
}

/* Matrix info box — full width */
#lorentz-tutorial .lorentz-matrix-container {
  margin-top: 12px;
  padding: 14px;
  width: 100%;
  background: #111;
  border: 1px solid #333;
  border-radius: 8px;
  font-family: 'Courier New', Courier, monospace;
  box-sizing: border-box;
}

#lorentz-tutorial .lorentz-scale-toggle {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 12px;
}

#lorentz-tutorial .lorentz-scale-label {
  font-size: 13px;
  color: #fff;
}

#lorentz-tutorial .lorentz-unit-btn {
  background: #222;
  color: #fff;
  border: 1px solid #444;
  padding: 6px 12px;
  cursor: pointer;
  font-size: 13px;
  font-family: 'Courier New', monospace;
  border-radius: 4px;
}

#lorentz-tutorial .lorentz-unit-btn:hover {
  border-color: #ff9f00;
  color: #ff9f00;
}

#lorentz-tutorial .lorentz-unit-btn.lorentz-unit-active {
  background: #ff9f00;
  border-color: #ff9f00;
  color: #0a0a0c;
}

#lorentz-tutorial .lorentz-matrix-formula-section {
  margin-bottom: 14px;
}

#lorentz-tutorial .lorentz-matrix-title {
  font-size: 13px;
  color: #fff;
  margin-bottom: 4px;
}

#lorentz-tutorial .lorentz-matrix-sym-note {
  font-size: 12px;
  color: #00d4ff;
  margin-bottom: 10px;
}

#lorentz-tutorial .lorentz-matrix-formula-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  border-left: 2px solid #444;
  border-right: 2px solid #444;
  padding: 10px 14px;
  margin: 10px 0 0 0;
}

#lorentz-tutorial .lorentz-matrix-symbol {
  text-align: center;
  padding: 10px;
  background: #1a1a1a;
  color: #fff;
  font-size: 14px;
}

#lorentz-tutorial .lorentz-matrix-result-label {
  font-size: 13px;
  color: #fff;
  margin: 14px 0 8px 0;
}

#lorentz-tutorial .lorentz-matrix-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  border-left: 2px solid #444;
  border-right: 2px solid #444;
  padding: 10px 14px;
  margin: 10px 0 0 0;
}

#lorentz-tutorial .lorentz-matrix-cell {
  text-align: center;
  padding: 10px;
  background: #1a1a1a;
  color: #ff9f00;
  font-weight: bold;
  font-size: 14px;
}
