/* The account pages around the viewer. Same palette as the plan view, so moving
   between a project list and a drawing does not feel like two different programs. */
:root {
  --paper: #f2f1ec;
  --sheet: #fffefb;
  --ink: #1b1a17;
  --muted: #6d6a62;
  --line: #d9d6cd;
  --accent: #2f5d50;
  --accent-soft: #e4ece9;
  --error: #9b2c2c;
  --error-soft: #f6e5e5;
  --warning: #8a6116;
  --warning-soft: #f7efdf;
  --info: #2b5b7a;
  --info-soft: #e3edf3;
  --radius: 3px;
  --sans: "Inter", "Helvetica Neue", Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", Menlo, monospace;
  color-scheme: light;
}

* { box-sizing: border-box; }
body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font: 15px/1.55 var(--sans);
}
a { color: var(--accent); }
a:hover { color: var(--ink); }

.masthead {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  padding: 0.9rem 1.5rem;
  background: var(--sheet);
  border-bottom: 1px solid var(--line);
}
.wordmark {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font: 600 0.9rem/1 var(--sans);
  letter-spacing: 0.14em;
  text-decoration: none;
  color: var(--ink);
}
/* The brand mark: a square with an inner corner, the same drawing the viewer uses. */
.brand-mark { width: 21px; height: 21px; border: 1.5px solid var(--ink); position: relative; flex: none; }
.brand-mark::after { content: ""; position: absolute; width: 13px; height: 13px; border-left: 1.5px solid var(--ink); border-top: 1.5px solid var(--ink); right: -1.5px; bottom: -1.5px; }
.product-label { margin-left: 15px; padding-left: 26px; border-left: 1px solid var(--line); font-family: var(--mono); font-size: 10px; letter-spacing: .06em; font-weight: 400; color: var(--muted); }
@media (max-width: 640px) { .product-label { display: none; } .brand-mark { width: 18px; height: 18px; } .brand-mark::after { width: 11px; height: 11px; } }
.masthead nav { margin-left: auto; display: flex; gap: 1.1rem; align-items: center; }
.masthead nav a { font-size: 0.85rem; text-decoration: none; }
.who { color: var(--muted); font-size: 0.8rem; }

main { max-width: 68rem; margin: 0 auto; padding: 2rem 1.5rem 4rem; }
main.narrow { max-width: 30rem; }
h1 { font-size: 1.35rem; margin: 0 0 0.3rem; }
h2 { font-size: 1rem; margin: 2rem 0 0.6rem; }
.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.12em;
  font-size: 0.7rem;
  color: var(--muted);
  margin: 0 0 0.4rem;
}
.lede { color: var(--muted); margin: 0 0 1.6rem; }

.card {
  background: var(--sheet);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 1.2rem 1.4rem;
  margin-bottom: 1rem;
}

table { width: 100%; border-collapse: collapse; font-size: 0.88rem; }
th, td { text-align: left; padding: 0.55rem 0.7rem; border-bottom: 1px solid var(--line); }
th { font-weight: 600; color: var(--muted); font-size: 0.75rem; text-transform: uppercase; letter-spacing: 0.08em; }
tr:last-child td { border-bottom: none; }
td.right, th.right { text-align: right; }

label { display: block; font-size: 0.8rem; color: var(--muted); margin: 0.9rem 0 0.25rem; }
input[type=text], input[type=email], input[type=password], input[type=number], select, textarea {
  width: 100%;
  padding: 0.5rem 0.6rem;
  font: inherit;
  color: var(--ink);
  background: var(--sheet);
  border: 1px solid var(--line);
  border-radius: var(--radius);
}
textarea { min-height: 6rem; }
input:focus, select:focus, textarea:focus { outline: 2px solid var(--accent); outline-offset: 1px; }

button, .button {
  font: 500 0.85rem/1 var(--sans);
  padding: 0.55rem 0.9rem;
  border-radius: var(--radius);
  border: 1px solid var(--accent);
  background: var(--accent);
  color: var(--sheet);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
button.secondary, .button.secondary { background: var(--sheet); color: var(--accent); }
button.danger { background: var(--sheet); border-color: var(--error); color: var(--error); }
button:hover { filter: brightness(1.08); }
.actions { display: flex; gap: 0.6rem; align-items: center; margin-top: 1.2rem; flex-wrap: wrap; }
form.inline { display: inline; }

.notice { padding: 0.7rem 0.9rem; border-radius: var(--radius); margin-bottom: 1.2rem; font-size: 0.88rem; }
.notice.error { background: var(--error-soft); color: var(--error); }
.notice.ok { background: var(--accent-soft); color: var(--accent); }
.notice.warn { background: var(--warning-soft); color: var(--warning); }

code, pre, .mono { font-family: var(--mono); font-size: 0.82rem; }
pre {
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 0.8rem;
  overflow-x: auto;
  white-space: pre-wrap;
  word-break: break-all;
}
.pill {
  display: inline-block;
  padding: 0.12rem 0.45rem;
  border-radius: 999px;
  font-size: 0.72rem;
  background: var(--info-soft);
  color: var(--info);
}
.pill.new { background: var(--warning-soft); color: var(--warning); }
.pill.fixed { background: var(--accent-soft); color: var(--accent); }
.pill.critical, .pill.high { background: var(--error-soft); color: var(--error); }
.muted { color: var(--muted); }
.empty { color: var(--muted); padding: 1.4rem 0; }

footer {
  border-top: 1px solid var(--line);
  padding: 1.2rem 1.5rem;
  color: var(--muted);
  font-size: 0.78rem;
  display: flex;
  gap: 1.2rem;
  flex-wrap: wrap;
}

@media (max-width: 640px) {
  .masthead { flex-wrap: wrap; gap: 0.6rem 1rem; }
  main { padding: 1.4rem 1rem 3rem; }
  table, thead, tbody, th, td, tr { display: block; }
  thead { display: none; }
  td { border: none; padding: 0.2rem 0; }
  tr { border-bottom: 1px solid var(--line); padding: 0.7rem 0; }
}

/* Revision comparison */
.diff-svg svg { width: 100%; height: auto; display: block; }
.diff-plan h2 { margin-top: 0.4rem; }
.pill.diff-added { background: #dff3e6; color: #1f8a4c; }
.pill.diff-changed { background: #f7efdf; color: #8a6116; }
.pill.diff-removed { background: #f6e5e5; color: #9b2c2c; }
.button-link { font-size: 0.85rem; margin-right: 0.6rem; }
