/* main.css — global design system for llamers.com
 *
 * A deliberately technical, terminal-adjacent identity: deep slate canvas, warm
 * amber accent (the llama), a humanist sans for prose and a mono for anything
 * numeric/mechanical. Tokens first, then a light base layer. Widgets bring their
 * own scoped styles; pages may add `.page.css`.
 */
:root {
  /* palette */
  --bg: #0d1017;
  --bg-raised: #151a23;
  --bg-inset: #0a0d13;
  --border: #232b38;
  --border-bright: #38465c;
  --text: #e6ebf2;
  --text-dim: #9aa7ba;
  --text-faint: #5e6b7e;
  --accent: #f5a623; /* amber */
  --accent-soft: #f5a62322;
  --accent-2: #4fd1c5; /* teal, for secondary data */
  --good: #5bd6a0;
  --bad: #ff6b6b;

  /* type */
  --font-sans: "Inter", ui-sans-serif, system-ui, -apple-system, "Segoe UI", sans-serif;
  --font-mono: "JetBrains Mono", ui-monospace, "SF Mono", "Fira Code", monospace;

  /* scale */
  --r: 10px;
  --r-sm: 6px;
  --maxw: 64rem;

  color-scheme: dark;
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background:
    radial-gradient(1200px 600px at 85% -10%, #1a2233 0%, transparent 60%),
    var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

h1, h2, h3 { line-height: 1.2; letter-spacing: -0.02em; font-weight: 650; }
h1 { font-size: clamp(2rem, 5vw, 3rem); }
h2 { font-size: 1.6rem; margin-top: 2.5rem; }
h3 { font-size: 1.2rem; }

code, kbd, samp { font-family: var(--font-mono); font-size: 0.9em; }

:not(pre) > code {
  background: var(--bg-inset);
  border: 1px solid var(--border);
  border-radius: var(--r-sm);
  padding: 0.1em 0.4em;
  color: var(--accent-2);
}

pre {
  background: var(--bg-inset);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1rem 1.1rem;
  overflow-x: auto;
}

hr { border: none; border-top: 1px solid var(--border); margin: 2rem 0; }

/* buttons */
button {
  font: inherit;
  cursor: pointer;
  border-radius: var(--r-sm);
  border: 1px solid var(--border-bright);
  background: var(--bg-raised);
  color: var(--text);
  padding: 0.5rem 0.9rem;
  transition: border-color 0.15s, background 0.15s, transform 0.05s;
}
button:hover { border-color: var(--accent); }
button:active { transform: translateY(1px); }
button.primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #1a1206;
  font-weight: 600;
}
button.primary:hover { background: #ffb53d; }
button:disabled { opacity: 0.5; cursor: not-allowed; }

input, select, textarea {
  font: inherit;
  color: var(--text);
  background: var(--bg-inset);
  border: 1px solid var(--border-bright);
  border-radius: var(--r-sm);
  padding: 0.45rem 0.6rem;
}
input:focus, select:focus, textarea:focus, button:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 1px;
}

/* app shell injected by routes/index layout */
.shell { min-height: 100vh; display: flex; flex-direction: column; }
.topbar {
  display: flex; align-items: center; gap: 1.5rem;
  padding: 0.9rem clamp(1rem, 4vw, 2rem);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 10;
  background: color-mix(in oklab, var(--bg) 86%, transparent);
  backdrop-filter: blur(8px);
}
.brand { font-weight: 700; letter-spacing: -0.03em; font-size: 1.15rem; }
.brand .dot { color: var(--accent); }
.topbar nav { display: flex; gap: 1.2rem; margin-left: auto; }
.topbar nav a { color: var(--text-dim); font-size: 0.95rem; }
.topbar nav a:hover { color: var(--text); text-decoration: none; }

.viewport { flex: 1; width: 100%; max-width: var(--maxw); margin: 0 auto; padding: clamp(1.5rem, 4vw, 3rem); }
.viewport.wide { max-width: 80rem; }

.muted { color: var(--text-dim); }
.mono { font-family: var(--font-mono); }
