/* Plain CSS, no build step (Propshaft serves this file as-is). */
:root {
  --bg: #f7f5f0;
  --surface: #ffffff;
  --text: #1d1b18;
  --muted: #6b665d;
  --border: #ddd8cc;
  --accent: #7a4b1c;
  --accent-text: #ffffff;
  --danger: #a3261b;
  --notice-bg: #e6f2e6;
  --alert-bg: #f8e3e0;
  color-scheme: light dark;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #171614;
    --surface: #211f1c;
    --text: #ece8e0;
    --muted: #a39d92;
    --border: #3a3631;
    --accent: #d99a57;
    --accent-text: #1d1b18;
    --danger: #e0685c;
    --notice-bg: #1f3320;
    --alert-bg: #3d2320;
  }
}

* { box-sizing: border-box; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font: 16px/1.55 system-ui, -apple-system, "Segoe UI", sans-serif;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

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

main {
  flex: 1;
  width: 100%;
  max-width: 44rem;
  margin: 0 auto;
  padding: 1.5rem 1rem 3rem;
}

.site-header, .site-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border);
}
.site-footer { border-bottom: 0; border-top: 1px solid var(--border); color: var(--muted); font-size: 0.875rem; }
.site-header nav { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.brand { font-weight: 700; font-size: 1.125rem; color: var(--text); text-decoration: none; }

.hero h1 { font-size: 2rem; line-height: 1.2; margin-top: 2rem; }
.muted { color: var(--muted); }

.flash { padding: 0.5rem 0.75rem; border-radius: 6px; }
.flash.notice { background: var(--notice-bg); }
.flash.alert { background: var(--alert-bg); }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: 8px; padding: 0 1rem 1rem; margin: 1.5rem 0; }
.card.danger { border-color: var(--danger); }

.stack { display: flex; flex-direction: column; gap: 0.35rem; max-width: 24rem; }
.stack input[type=submit] { margin-top: 0.75rem; align-self: flex-start; }
.row { display: flex; gap: 0.5rem; flex-wrap: wrap; align-items: center; }
.row form { margin: 0; }

input[type=text], input[type=email], input[type=password] {
  font: inherit;
  padding: 0.45rem 0.6rem;
  border: 1px solid var(--border);
  border-radius: 6px;
  background: var(--surface);
  color: var(--text);
  min-width: 0;
}

input[type=submit], button, .button {
  font: inherit;
  padding: 0.45rem 0.9rem;
  border: 1px solid var(--accent);
  border-radius: 6px;
  background: var(--accent);
  color: var(--accent-text);
  cursor: pointer;
  text-decoration: none;
  display: inline-block;
}
.secondary, input[type=submit].secondary { background: transparent; color: var(--accent); }
.destructive, input[type=submit].destructive { background: var(--danger); border-color: var(--danger); color: #fff; }
button.link { background: none; border: 0; padding: 0; color: var(--accent); text-decoration: underline; }
form.button_to { display: inline; }

.errors { color: var(--danger); padding-left: 1.25rem; }
.code, .code-input { font-family: ui-monospace, "SF Mono", Menlo, monospace; letter-spacing: 0.08em; }
.code-input { text-transform: uppercase; width: 11rem; }

table { width: 100%; border-collapse: collapse; font-size: 0.9375rem; }
th, td { text-align: left; padding: 0.4rem 0.5rem 0.4rem 0; border-bottom: 1px solid var(--border); }
.checkbox { display: flex; align-items: center; gap: 0.4rem; margin-top: 0.5rem; }
.google { width: 100%; max-width: 24rem; background: var(--surface); color: var(--text); border-color: var(--border); }
.divider { display: flex; align-items: center; gap: 0.75rem; max-width: 24rem; color: var(--muted); font-size: 0.875rem; }
.divider::before, .divider::after { content: ""; flex: 1; border-top: 1px solid var(--border); }
