.number-line-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 1rem 0 0.75rem;
}

.number-line-tab {
  appearance: none;
  border: 1px solid #d0d7de;
  border-bottom: none;
  border-radius: 8px 8px 0 0;
  background: #f6f8fa;
  color: #24292f;
  cursor: pointer;
  padding: 0.5rem 0.9rem;
  font-weight: 500;
}

.number-line-tab:focus-visible {
  outline: 3px solid #0b57d0;
  outline-offset: 2px;
}

.number-line-tab.active {
  background: #ffffff;
  font-weight: 600;
}

.number-line-tabpanel.hidden {
  display: none;
}

.number-line-domain {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 0.5rem 0 1rem;
}

.number-line-domain label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  min-width: 10rem;
}

.number-line-domain input {
  padding: 0.45rem 0.6rem;
}

.number-line-tabpanel label {
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
  margin-bottom: 0.75rem;
}

.number-line-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1rem;
}

.number-line-actions button {
  cursor: pointer;
}

.number-line-actions .primary {
  background: #0b57d0;
  border: 1px solid #0b57d0;
  color: #ffffff;
}

.number-line-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: 1.25rem;
}

@media (max-width: 960px) {
  .number-line-layout {
    grid-template-columns: 1fr;
  }
}

#plotHost {
  border: 1px dashed #d0d7de;
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #fafbfc;
  padding: 1rem;
  overflow-x: auto;
}

#plotHost svg {
  max-width: 100%;
  height: auto;
  box-shadow: 0 0 0 1px #eaeef2;
}

#notation {
  margin-top: 0.75rem;
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  font-size: 0.95rem;
  color: #1f2328;
  word-break: break-word;
}

#preview-status,
#share-status {
  font-size: 0.9rem;
  color: #475467;
  margin-top: 0.5rem;
}

#err {
  margin-top: 0.75rem;
  color: #b42318;
  font-weight: 600;
}

.number-line-builder {
  width: 100%;
  border-collapse: collapse;
  margin-top: 0.5rem;
}

.number-line-builder th,
.number-line-builder td {
  border: 1px solid #d0d7de;
  padding: 0.45rem 0.6rem;
  text-align: left;
}

.number-line-builder input,
.number-line-builder select {
  width: 100%;
  box-sizing: border-box;
}

.number-line-remove {
  background: transparent;
  border: 1px solid #d0d7de;
  border-radius: 4px;
  color: #b42318;
  padding: 0.25rem 0.5rem;
}

.number-line-remove:focus-visible {
  outline: 3px solid #0b57d0;
  outline-offset: 2px;
}

.number-line-select {
  padding: 0.4rem 0.5rem;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

@media print {
  header,
  nav,
  .lang-switch,
  .number-line-tabs,
  .number-line-actions,
  .ad-slot,
  #comments,
  footer,
  #share-status {
    display: none !important;
  }
  main.container {
    max-width: none;
    margin: 0;
    padding: 0;
  }
  #plotHost {
    border: none;
    box-shadow: none;
    min-height: 0;
    padding: 0;
  }
}
