:root {
  --paper: #f3f1ec;
  --ink: #1d1d1b;
  --mute: #6b6a64;
  --line: #dcd8ce;
  --fog: #e9e6de;
  --acid: #effd6b;
  --white: #fffefb;
  --danger: #a8432c;
  --display: "Bricolage Grotesque", ui-sans-serif, system-ui, sans-serif;
  --mono: "Fragment Mono", ui-monospace, monospace;
  --ease: cubic-bezier(0.2, 0.7, 0.1, 1);
  color-scheme: light;
}
* { box-sizing: border-box; }
html, body { margin: 0; height: 100%; }
body {
  background: var(--paper);
  color: var(--ink);
  font: 15px/1.45 var(--display);
  -webkit-font-smoothing: antialiased;
}
button, input, textarea { font: inherit; color: inherit; }
a { color: inherit; }
.mono { font-family: var(--mono); font-size: 12px; letter-spacing: 0.01em; }
.muted { color: var(--mute); }
[hidden] { display: none !important; }

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  height: 36px; padding: 0 14px; border-radius: 999px; border: 1px solid var(--ink);
  background: var(--ink); color: var(--paper); font-weight: 500; cursor: pointer;
  text-decoration: none; white-space: nowrap;
  transition: transform 0.12s var(--ease), background 0.15s, opacity 0.15s;
}
.btn:active { transform: scale(0.97); }
.btn:disabled { opacity: 0.45; cursor: default; }
.btn.ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn.ghost:hover { border-color: var(--ink); }
.btn.acid { background: var(--acid); color: var(--ink); border-color: var(--ink); }
.btn.sm { height: 30px; padding: 0 11px; font-size: 13px; }
.btn.danger { background: transparent; color: var(--danger); border-color: transparent; }
.btn.danger:hover { border-color: var(--danger); }
.btn svg { width: 16px; height: 16px; flex: none; }

.field {
  width: 100%; height: 44px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px;
  background: var(--white); outline: none; transition: border-color 0.15s, box-shadow 0.15s;
}
textarea.field { height: auto; min-height: 84px; padding: 11px 14px; resize: vertical; line-height: 1.45; }
.field:focus { border-color: var(--ink); box-shadow: 0 0 0 3px rgba(239, 253, 107, 0.9); }

.logo { display: inline-flex; align-items: center; gap: 9px; font-weight: 800; letter-spacing: -0.02em; text-decoration: none; }
.logo i { width: 22px; height: 22px; border-radius: 6px; background: var(--acid); border: 1.5px solid var(--ink); display: inline-block; position: relative; }
.logo i::after { content: ""; position: absolute; left: 4px; bottom: 3px; width: 8px; height: 8px; border-radius: 50% 50% 50% 2px; background: var(--ink); }

.toast {
  position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 20px); opacity: 0;
  background: var(--ink); color: var(--paper); padding: 10px 16px; border-radius: 999px; font-size: 14px;
  transition: all 0.25s var(--ease); pointer-events: none; z-index: 100;
}
.toast.show { opacity: 1; transform: translate(-50%, 0); }

.spinner {
  width: 22px; height: 22px; border-radius: 50%; border: 2.5px solid var(--line); border-top-color: var(--ink);
  animation: spin 0.8s linear infinite;
}
@keyframes spin { to { transform: rotate(360deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
