:root {
  --bg: #0f1115;
  --card: #1a1d24;
  --border: #2a2e38;
  --text: #e6e9ef;
  --muted: #8b93a3;
  --accent: #4ca6ff;
  --accent-dark: #2f7fd1;
  --green: #3ecf8e;
  --red: #ff6b6b;
  --yellow: #ffc94d;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica,
    Arial, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.5;
}

.container {
  max-width: 960px;
  margin: 0 auto;
  padding: 24px;
}

header {
  margin-bottom: 24px;
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.header-btn {
  align-self: auto;
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 14px;
  font-size: 0.85rem;
}

.header-btn:hover {
  background: #222631;
  color: var(--text);
}

.muted {
  color: var(--muted);
  margin-top: 0;
}

#loginCard {
  max-width: 420px;
}

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

.subtitle {
  margin: 4px 0 0;
  color: var(--muted);
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 20px;
  margin-bottom: 20px;
}

.card h2 {
  margin: 0 0 12px;
  font-size: 1.15rem;
}

.endpoints {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 12px;
}

.endpoint {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  padding: 10px;
  background: #14161c;
  border-radius: 8px;
  font-size: 0.9rem;
}

.method {
  font-weight: 700;
  font-size: 0.75rem;
  padding: 3px 8px;
  border-radius: 4px;
  letter-spacing: 0.03em;
}

.method.get {
  background: #16341f;
  color: var(--green);
}

code {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  color: #c8d1e0;
  word-break: break-all;
}

.hint {
  color: var(--muted);
  margin-left: auto;
}

.status-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.status-row:last-child {
  border-bottom: none;
}

.label {
  color: var(--muted);
}

.badge {
  background: #14161c;
  border: 1px solid var(--border);
  padding: 4px 10px;
  border-radius: 20px;
  font-family: "SFMono-Regular", Consolas, Menlo, monospace;
  font-size: 0.85rem;
}

.form {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.form-row {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.form-row label {
  font-size: 0.9rem;
  color: var(--muted);
}

.form-row.checkbox label {
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
}

input[type="text"],
input[type="password"],
input[type="file"] {
  background: #14161c;
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  color: var(--text);
  font-size: 0.95rem;
}

input[type="text"]:focus,
input[type="password"]:focus {
  outline: none;
  border-color: var(--accent);
}

input[type="file"] {
  cursor: pointer;
}

button {
  background: var(--accent);
  color: #0a0c10;
  border: none;
  border-radius: 8px;
  padding: 12px 22px;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.15s ease;
  align-self: flex-start;
}

button:hover {
  background: var(--accent-dark);
  color: #fff;
}

button:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

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

.table th,
.table td {
  text-align: left;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border);
}

.table th {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.pill {
  display: inline-block;
  padding: 3px 10px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
}

.pill.active {
  background: #16341f;
  color: var(--green);
}

.pill.inactive {
  background: #241e10;
  color: var(--yellow);
}

.action-btn {
  background: transparent;
  border: 1px solid var(--border);
  border-radius: 6px;
  color: var(--text);
  font-size: 0.8rem;
  padding: 6px 10px;
  margin-right: 6px;
  cursor: pointer;
  align-self: auto;
}

.action-btn:hover {
  background: #222631;
  color: var(--text);
}

.action-btn.danger {
  border-color: #4a2528;
  color: var(--red);
}

.action-btn.danger:hover {
  background: #4a2528;
}

.message {
  margin-top: 14px;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 0.9rem;
}

.message.success {
  background: #14352a;
  color: var(--green);
}

.message.error {
  background: #3a2022;
  color: var(--red);
}

.progress {
  margin-top: 14px;
  height: 8px;
  background: #14161c;
  border-radius: 4px;
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  background: var(--accent);
  width: 0;
  transition: width 0.2s ease;
}

.hidden {
  display: none;
}

footer {
  text-align: center;
  color: var(--muted);
  margin-top: 24px;
  font-size: 0.85rem;
}