:root {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  color: #0f172a;
  background-color: #f8fafc;
}

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2rem;
}

.card {
  width: min(520px, 100%);
  background: #fff;
  border-radius: 16px;
  padding: 2rem;
  box-shadow: 0 20px 40px rgba(15, 23, 42, 0.1);
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

header h1 {
  margin: 0 0 0.25rem;
  font-size: 1.75rem;
}

header p {
  margin: 0;
  color: #475569;
}

form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.field {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-weight: 600;
  color: #334155;
}

.option-group {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-weight: 500;
}

.option-group label {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-weight: 500;
  color: #1e293b;
}

input,
select {
  font: inherit;
  padding: 0.65rem 0.75rem;
  border: 1px solid #cbd5f5;
  border-radius: 8px;
}

.static-field {
  padding: 0.65rem 0.75rem;
  border: 1px solid #e2e8f0;
  border-radius: 8px;
  background: #f1f5f9;
}

button {
  border: none;
  border-radius: 999px;
  padding: 0.75rem;
  font: inherit;
  font-weight: 600;
  color: #fff;
  background: linear-gradient(120deg, #2563eb, #7c3aed);
  cursor: pointer;
}

button:disabled {
  opacity: 0.6;
  cursor: wait;
}

#result,
#error {
  border-radius: 12px;
  padding: 1rem;
  border: 1px solid #e2e8f0;
  background: #f8fafc;
}

.result-row {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-top: 0.5rem;
  word-break: break-all;
}

.error {
  color: #b91c1c;
  border-color: #fecaca;
  background: #fff5f5;
}

.hidden {
  display: none;
}
