:root {
  --bg: #f6f4ef;
  --ink: #1a1a1a;
  --muted: #5c5c5c;
  --line: #d8d2c4;
  --accent: #0b5fff;
  --ok: #1a7a3c;
  --err: #b00020;
  --card: #fff;
  --radius: 6px;
  font-family: "Segoe UI", system-ui, sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.45;
}

.wrap {
  max-width: 900px;
  margin: 0 auto;
  padding: 2rem 1.25rem 3rem;
}

.wrap.narrow {
  max-width: 380px;
  margin-top: 4rem;
}

.top {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
  padding-bottom: 0.75rem;
}

h1 {
  margin: 0;
  font-size: 1.5rem;
  font-weight: 650;
}

h2 {
  margin: 2rem 0 0.75rem;
  font-size: 1.1rem;
}

nav {
  display: flex;
  gap: 1rem;
}

a {
  color: var(--accent);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

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

.error {
  color: var(--err);
}

.ok {
  color: var(--ok);
}

.stack {
  display: flex;
  flex-direction: column;
  gap: 0.85rem;
}

label {
  display: flex;
  flex-direction: column;
  gap: 0.35rem;
  font-size: 0.9rem;
}

input[type="password"],
input[type="text"],
textarea {
  font: inherit;
  padding: 0.55rem 0.7rem;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
}

button {
  font: inherit;
  padding: 0.55rem 1rem;
  border: none;
  border-radius: var(--radius);
  background: var(--ink);
  color: #fff;
  cursor: pointer;
  width: fit-content;
}

button:hover {
  opacity: 0.9;
}

button.danger {
  background: transparent;
  color: var(--err);
  border: 1px solid var(--err);
  padding: 0.25rem 0.55rem;
  font-size: 0.85rem;
}

table {
  width: 100%;
  border-collapse: collapse;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

th,
td {
  text-align: left;
  padding: 0.75rem 0.9rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
  word-break: break-all;
}

th {
  background: #efeae0;
  font-size: 0.85rem;
  font-weight: 600;
}

tr:last-child td {
  border-bottom: none;
}

.url-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: var(--card);
}

.url-list li {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.7rem 0.9rem;
  border-bottom: 1px solid var(--line);
}

.url-list li:last-child {
  border-bottom: none;
}

.url-list .url {
  word-break: break-all;
}

.inline {
  margin: 0;
  flex-shrink: 0;
}

@media (max-width: 600px) {
  .top {
    flex-direction: column;
    align-items: flex-start;
  }

  th:nth-child(2),
  td:nth-child(2) {
    white-space: nowrap;
  }
}
