:root {
  color-scheme: light;
  font-family: system-ui, -apple-system, "Segoe UI", sans-serif;
  color: #313b49;
  background: #f7f8fa;
  font-synthesis: none;
}

* { box-sizing: border-box; }
body { margin: 0; }
button, input { font: inherit; }
button, input { min-height: 36px; border: 1px solid #d9dfe7; border-radius: 5px; background: #fff; color: inherit; }
button { padding: 0 15px; cursor: pointer; }
button:hover { background: #f0f3f7; }
button:disabled { opacity: .45; cursor: default; }
button:focus-visible, input:focus-visible { outline: 2px solid #779ed6; outline-offset: 3px; }
input[type="number"] { width: 86px; padding: 6px 9px; font-variant-numeric: tabular-nums; }
.simulator { width: min(1080px, calc(100% - 40px)); margin: 36px auto; font-size: 14px; }
.controls { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 24px; margin-bottom: 18px; }
.parameter { display: flex; align-items: center; gap: 10px; white-space: nowrap; }
.angle-input { display: inline-flex; align-items: center; gap: 5px; }
.buttons { display: flex; gap: 8px; margin-left: auto; }
.primary { background: #4279be; border-color: #4279be; color: #fff; min-width: 66px; }
.primary:hover { background: #3469aa; }
.canvas-wrap { height: clamp(300px, 58vh, 540px); border: 1px solid #e0e5eb; border-radius: 6px; overflow: hidden; background: #fff; }
#scene { display: block; width: 100%; height: 100%; cursor: crosshair; }
.timeline { display: flex; align-items: center; gap: 18px; margin-top: 12px; }
.timeline input { flex: 1; min-width: 0; height: 24px; min-height: 24px; margin: 0; padding: 0; border: 0; accent-color: #4279be; cursor: pointer; }
.timeline output { min-width: 105px; text-align: right; color: #6d7785; font-size: 13px; font-variant-numeric: tabular-nums; }
.point-form { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 24px; }
.point-form > label { margin-right: 4px; }
.hint { color: #89919c; margin-left: 7px; font-size: 12px; }
.text-button { background: transparent; border-color: transparent; color: #77818e; padding: 0 7px; }
.point-list { display: flex; flex-wrap: wrap; gap: 8px; margin-top: 12px; }
.point-item { display: flex; align-items: center; gap: 12px; min-height: 34px; padding: 3px 6px 3px 12px; border: 1px solid #e2e6eb; border-radius: 5px; background: #fff; font-size: 12px; font-variant-numeric: tabular-nums; max-width: 100%; }
.point-coords { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.point-result { color: #287c58; white-space: nowrap; }
.is-outside .point-result { color: #b6633e; }
.point-delete { min-height: 26px; width: 25px; padding: 0; border: 0; background: transparent; color: #89919c; font-size: 17px; }
.point-delete:hover { background: #f7f8fa; color: #b04f4f; }

@media (max-width: 560px) {
  .simulator { width: calc(100% - 24px); margin: 20px auto; }
  .controls { gap: 12px 18px; margin-bottom: 14px; }
  .buttons { width: 100%; margin-left: 0; }
  .canvas-wrap { height: 340px; }
  .point-form { gap: 8px; }
  .point-form input[type="number"] { width: 65px; }
  .point-form button { padding-left: 10px; padding-right: 10px; }
  .point-form .text-button { padding: 0 4px; }
  .hint { flex-basis: 100%; margin-left: 0; margin-top: 2px; }
  .timeline { gap: 12px; }
}
