/* Hand-written and deliberately small. There is no CSS build step and no
   node on this machine; see the README. */

:root {
  --ink: #1a1a1a;
  --muted: #5c5c5c;
  --line: #d8d4cc;
  --paper: #faf9f7;
  --accent: #1f4f82;
  --bad: #a11b1b;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif;
}

header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.75rem 1.25rem;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.brand {
  font-weight: 600;
  letter-spacing: 0.02em;
  color: var(--ink);
  text-decoration: none;
}

.row { display: flex; align-items: center; gap: 0.75rem; margin: 0; }
.who { color: var(--muted); font-size: 0.9rem; }

main {
  max-width: 34rem;
  margin: 0 auto;
  padding: 2rem 1.25rem;
}

h1 { font-size: 1.4rem; margin: 0 0 1rem; }

.stack { display: flex; flex-direction: column; gap: 0.4rem; }
.stack label { font-size: 0.85rem; color: var(--muted); margin-top: 0.5rem; }

input[type="text"], input[type="password"], input:not([type]) {
  padding: 0.5rem 0.6rem;
  border: 1px solid var(--line);
  border-radius: 4px;
  background: #fff;
  font: inherit;
}

input:focus-visible, button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

button {
  margin-top: 1rem;
  padding: 0.5rem 0.9rem;
  border: 1px solid var(--accent);
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  cursor: pointer;
}

button.link {
  margin: 0;
  padding: 0;
  border: 0;
  background: none;
  color: var(--accent);
  text-decoration: underline;
}

.error {
  padding: 0.6rem 0.8rem;
  border-left: 3px solid var(--bad);
  background: #fdf2f2;
  color: var(--bad);
}

.note { color: var(--muted); font-size: 0.9rem; }

nav { margin-right: auto; margin-left: 1.5rem; }
nav a { color: var(--accent); }

main { max-width: 42rem; }

table {
  width: 100%;
  border-collapse: collapse;
  margin: 1rem 0;
}

th, td {
  text-align: left;
  padding: 0.5rem 0.6rem;
  border-bottom: 1px solid var(--line);
}

th { font-size: 0.85rem; color: var(--muted); font-weight: 600; }

.actions { width: 1%; white-space: nowrap; text-align: right; }
.actions a { margin-right: 0.75rem; }

/* An inline form so a delete can be a POST and still sit in a row of
   links: the button is styled as one. */
.inline { display: inline; margin: 0; }

.danger { color: var(--bad); }

/* A link that acts as the page's primary action. */
.button {
  display: inline-block;
  padding: 0.4rem 0.8rem;
  border: 1px solid var(--accent);
  border-radius: 4px;
  background: var(--accent);
  color: #fff;
  text-decoration: none;
}

.menu { padding-left: 1.1rem; }
.menu li { margin: 0.25rem 0; }

.stack .row { margin-top: 1rem; }
.stack .row button { margin-top: 0; }

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}
