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

body {
  margin: 0;
  padding: 2rem;
  background: #0f172a;
}

.app-header {
  color: #f8fafc;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.5rem;
}

.subtitle {
  margin: 0.2rem 0 0;
  font-size: 0.9rem;
  color: #94a3b8;
}

main {
  max-width: 1200px;
  margin: 0 auto;
}

.card {
  background: #ffffff;
  border-radius: 16px;
  padding: 1.5rem;
  box-shadow: 0 20px 50px rgba(15, 23, 42, 0.2);
}

.table-wrapper {
  overflow-x: auto;
}

.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.legend {
  display: flex;
  gap: 0.5rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.95rem;
}

th,
td {
  text-align: left;
  padding: 0.75rem 0.5rem;
}

thead th {
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #64748b;
}

tbody tr {
  border-top: 1px solid #e2e8f0;
}

tbody tr.success {
  background: #f8fffb;
}

tbody tr.warning {
  background: #fffbea;
}

tbody tr.danger {
  background: #fff5f5;
}

.chip {
  display: inline-block;
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 600;
}

.chip.success {
  background: #dcfce7;
  color: #166534;
}

.chip.warning {
  background: #fef3c7;
  color: #92400e;
}

.chip.danger {
  background: #fee2e2;
  color: #b91c1c;
}

.meta {
  color: #475569;
  font-size: 0.8rem;
}

.alert-text {
  color: #b45309;
  font-weight: 600;
}

.mono {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;
}

.inline-form {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  margin-top: 0.5rem;
}

.api-cell {
  min-width: 240px;
}

.api-summary {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.api-form {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  margin-top: 0.5rem;
}

.api-row {
  display: flex;
  gap: 0.5rem;
}

.api-row input {
  flex: 1;
}

.port-input {
  max-width: 110px;
}

.api-form small {
  font-size: 0.7rem;
  color: #64748b;
}

input[type="text"],
input[type="number"],
input[type="password"],
input[type="email"] {
  border: 1px solid #cbd5f5;
  border-radius: 8px;
  padding: 0.45rem 0.6rem;
  font-size: 0.9rem;
}

button {
  border: none;
  border-radius: 999px;
  padding: 0.4rem 1.1rem;
  font-size: 0.85rem;
  font-weight: 600;
  cursor: pointer;
  background: #2563eb;
  color: #fff;
}

button.secondary {
  background: #e2e8f0;
  color: #0f172a;
}

button.danger {
  background: #dc2626;
}

.form-grid {
  display: flex;
  gap: 0.5rem;
  align-items: flex-end;
}

.alert {
  background: #fee2e2;
  color: #b91c1c;
  padding: 0.5rem 0.75rem;
  border-radius: 8px;
}
