:root {
  color-scheme: light;
  --ink: #1c1915;
  --muted: #5c564e;
  --paper: #f7f4ef;
  --card: #fffdf9;
  --line: #c9c1b4;
  --green: #1f4d3a;
  --green-ink: #f4f7f5;
  --alert: #7a1f1f;
}

* { box-sizing: border-box; }

html { font-size: 125%; }

body {
  margin: 0;
  font-family: "Iowan Old Style", Palatino, "Palatino Linotype", Georgia, serif;
  line-height: 1.5;
  color: var(--ink);
  background: var(--paper);
}

.skip {
  position: absolute;
  left: 0.5rem;
  top: -3rem;
  background: var(--green);
  color: var(--green-ink);
  padding: 0.4rem 0.7rem;
}

.skip:focus { top: 0.5rem; }

.site-header,
main {
  width: min(42rem, calc(100% - 2rem));
  margin-inline: auto;
}

.site-header {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem 1.25rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--line);
}

.brand {
  font-weight: 700;
  color: var(--ink);
  text-decoration: none;
  margin-right: auto;
}

.who {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

main { padding: 1.25rem 0 3rem; }

h1, h2 { line-height: 1.25; }

h1 { font-size: 1.8rem; margin: 0 0 0.75rem; }

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

a { color: var(--green); }

a:hover { text-decoration-thickness: 2px; }

p { margin: 0.6rem 0; }

.notice {
  background: #efe7d6;
  border-left: 4px solid var(--green);
  padding: 0.75rem 1rem;
}

.error {
  color: var(--alert);
  font-weight: 700;
}

.hint { color: var(--muted); font-size: 0.85rem; }

.auth-form,
.question form {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.4rem;
}

label { font-weight: 700; max-width: 40rem; }

input[type="email"],
input[type="password"],
input[type="text"],
textarea {
  width: min(100%, 36rem);
  font: inherit;
  color: inherit;
  background: var(--card);
  border: 1px solid #8a8175;
  border-radius: 0.2rem;
  padding: 0.55rem 0.7rem;
}

textarea {
  min-height: 8rem;
  resize: vertical;
  white-space: pre-wrap;
}

button {
  font: inherit;
  background: var(--green);
  color: var(--green-ink);
  border: 0;
  border-radius: 0.2rem;
  padding: 0.45rem 0.9rem;
  min-height: 2.4rem;
  cursor: pointer;
}

button:hover { background: #16382a; }

.site-header button {
  background: transparent;
  color: var(--green);
  border: 1px solid var(--green);
}

:focus-visible {
  outline: 3px solid var(--green);
  outline-offset: 2px;
}

.page-list {
  list-style: none;
  padding: 0;
  margin: 1.25rem 0 0;
}

.page-list li {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 0.25rem 1rem;
  padding: 0.7rem 0;
  border-bottom: 1px solid var(--line);
}

.page-list span { color: var(--muted); }

.narrative {
  white-space: pre-wrap;
  background: var(--card);
  border: 1px solid var(--line);
  padding: 0.9rem 1rem;
  margin: 0.75rem 0 1rem;
}

.question { margin: 1.5rem 0 2rem; }

.save-status {
  min-height: 1.5rem;
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.save-status.unsaved { color: var(--alert); }

.page-tools {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.25rem;
}

.sections ul { padding-left: 1.2rem; }

.crumbs { margin-top: 0; }
