* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: #f7f7f8;
  color: #1a1a1a;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.5;
}

main {
  max-width: 880px;
  margin: 0 auto;
  padding: 40px 24px 80px;
}

.page-header {
  margin-bottom: 24px;
}

.page-header h1 {
  font-size: 24px;
  font-weight: 600;
  margin: 0 0 4px;
  color: #111;
}

.tagline {
  margin: 0;
  color: #666;
  font-size: 14px;
}

form {
  background: #fff;
  border: 1px solid #e3e3e6;
  border-radius: 6px;
  padding: 20px;
}

textarea {
  width: 100%;
  min-height: 400px;
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 13px;
  line-height: 1.5;
  padding: 12px;
  border: 1px solid #d4d4d8;
  border-radius: 4px;
  resize: vertical;
  color: #111;
  background: #fafafa;
}

textarea:focus {
  outline: 2px solid #1f4788;
  outline-offset: -1px;
  border-color: #1f4788;
  background: #fff;
}

.format-select {
  border: none;
  padding: 0;
  margin: 16px 0 0 0;
  display: flex;
  gap: 20px;
  align-items: center;
  font-size: 14px;
}

.format-select legend {
  padding: 0;
  margin-right: 8px;
  color: #555;
  font-weight: 500;
}

.format-select label {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #333;
  cursor: pointer;
}

.format-select input[type="radio"] {
  margin: 0;
  accent-color: #1f4788;
}

.actions {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-top: 16px;
}

button {
  background: #1f4788;
  color: #fff;
  border: none;
  padding: 10px 20px;
  font-size: 14px;
  font-weight: 600;
  border-radius: 4px;
  cursor: pointer;
}

button:hover:not(:disabled) {
  background: #183764;
}

button:disabled {
  background: #9aa7bd;
  cursor: not-allowed;
}

.status {
  font-size: 13px;
  color: #555;
  min-height: 1.5em;
}

.status.error { color: #a1271a; }
.status.success { color: #1a6b38; }

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