:root {
  --bg: #f7f5f0;
  --paper: #fffdf8;
  --line: #e2ddd1;
  --text: #2b2823;
  --muted: #6b6458;
  --accent: #b5552f;
  --error: #b3261e;
}
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #1d1c1a;
    --paper: #232220;
    --line: #34322e;
    --text: #e8e4dc;
    --muted: #a39c90;
    --accent: #e08a62;
    --error: #f2867e;
  }
}

* {
  box-sizing: border-box;
}
html,
body {
  margin: 0;
  min-height: 100%;
}
body {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px 16px;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.5 -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
}

.card {
  width: 100%;
  max-width: 400px;
  padding: 40px 32px 32px;
  background: var(--paper);
  border: 1px solid var(--line);
  border-radius: 16px;
  text-align: center;
}
.mark {
  display: block;
  margin: 0 auto 12px;
}
h1 {
  margin: 0 0 4px;
  font: 600 32px/1.2 Fraunces, Georgia, serif;
  letter-spacing: -0.02em;
}
h2 {
  margin: 24px 0 8px;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}
.lede {
  margin: 0 0 28px;
  color: var(--muted);
}
#signed-in .lede {
  margin-bottom: 0;
}
#signed-in strong {
  color: var(--text);
}

button {
  font: inherit;
  cursor: pointer;
}
.fields {
  display: grid;
  gap: 6px;
  text-align: left;
}
.fields label {
  font-size: 14px;
  font-weight: 500;
}
.fields input {
  min-height: 44px;
  margin-bottom: 10px;
  padding: 0 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
}
.fields input:focus {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}
.fields .check {
  display: flex;
  align-items: center;
  gap: 8px;
  min-height: 44px;
  font-weight: 400;
  color: var(--muted);
}
.fields .check[hidden] {
  display: none;
}
.fields .check input {
  min-height: 0;
  margin: 0;
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}
.primary {
  min-height: 48px;
  margin-top: 6px;
  border: 0;
  border-radius: 10px;
  background: var(--text);
  color: var(--paper);
  font-weight: 600;
}
.primary:disabled {
  opacity: 0.6;
  cursor: progress;
}
.or {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--muted);
  font-size: 14px;
}
.or::before,
.or::after {
  content: '';
  flex: 1;
  border-top: 1px solid var(--line);
}
.or[hidden],
.google[hidden] {
  display: none;
}
.google {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  width: 100%;
  min-height: 48px;
  padding: 0 20px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #fff;
  color: #1f1f1f;
  font-weight: 500;
}
.google:hover {
  background: #f5f5f5;
}
.google:disabled {
  opacity: 0.6;
  cursor: progress;
}
.quiet {
  min-height: 44px;
  margin-top: 20px;
  padding: 0 16px;
  border: 0;
  background: none;
  color: var(--accent);
  text-decoration: underline;
}

#projects {
  list-style: none;
  margin: 0;
  padding: 0;
  text-align: left;
}
#projects li {
  padding: 10px 0;
  border-top: 1px solid var(--line);
}
#projects a {
  display: block;
  color: var(--text);
  font-weight: 500;
  text-decoration: none;
}
#projects a:hover {
  color: var(--accent);
}
#projects li:last-child {
  border-bottom: 1px solid var(--line);
}
#projects .empty {
  color: var(--muted);
  text-align: center;
  border: 0;
}

#message {
  margin: 20px 0 0;
  font-size: 14px;
  color: var(--muted);
}
#message:empty {
  display: none;
}
#message.error {
  color: var(--error);
}

/* The Connect Claude page (web/connect.html). */
#ask .lede strong {
  color: var(--text);
}
.grants {
  margin: -12px 0 24px;
  padding: 12px 16px 12px 32px;
  border: 1px solid var(--line);
  border-radius: 10px;
  text-align: left;
  font-size: 14px;
  color: var(--muted);
}
.grants li + li {
  margin-top: 4px;
}
#allow-form .lede {
  margin: 0 0 12px;
  text-align: center;
}
.fields select {
  min-height: 44px;
  margin-bottom: 10px;
  padding: 0 8px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
}
.fields[hidden] {
  display: none;
}
