/* Page-specific layout only — colors, fonts, buttons, panes, statusbar and the
   export-split control are inherited from styles.css. */

.tfge-layout {
  display: grid;
  grid-template-columns: minmax(300px, 410px) minmax(0, 1fr);
  gap: 16px;
  align-items: start;
}

.tfge-form { display: grid; gap: 0.9rem; }
.tfge-field { display: grid; gap: 0.28rem; }
.tfge-field label, .tfge-fieldset legend { font-weight: 700; }
.tfge-field input, .tfge-field select, .tfge-field textarea {
  width: 100%;
  border: 1px solid var(--border);
  border-radius: 0.4rem;
  padding: 0.45rem 0.55rem;
  font: inherit;
  background: var(--paper);
  color: var(--text);
}
#expressionInput { resize: none; }

.tfge-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 0.6rem; }

.tfge-fieldset {
  border: 1px solid var(--border);
  border-radius: 0.45rem;
  padding: 0.7rem;
  margin: 0;
}
.tfge-radio-row { display: flex; flex-wrap: wrap; gap: 0.85rem; margin-top: 0.35rem; }
.tfge-radio-row label { font-weight: 400; }

.tfge-field label.tfge-checkbox-label { display: flex; align-items: center; gap: 0.45rem; font-weight: 400; }
.tfge-checkbox-label input { width: auto; }

#preview {
  min-height: 320px;
  overflow: auto;
  border: 1px solid var(--border);
  border-radius: 0.45rem;
  padding: 0.75rem;
  background: var(--paper);
  cursor: zoom-in;
}
#preview svg { max-width: 100%; height: auto; display: block; margin: 0 auto; }

/* Vorschau entspricht (noch) nicht dem aktuellen Formularstand - siehe
   setPreviewStale() in tactile-function-graph.js. Der Text-Badge trägt die
   eigentliche Information, die Dimmung ist nur unterstützender Hinweis. */
#preview.stale { opacity: 0.6; }
.stale-badge { color: var(--error); font-weight: 700; font-size: 0.85em; margin-left: 0.4em; }

#zoomPreview svg { max-width: 100%; height: auto; display: block; margin: 0 auto; }

@media (max-width: 860px) {
  .tfge-layout { grid-template-columns: 1fr; }
}
