/* ============================================================
   common.css — plaintextlab
   Shared tokens, reset, layout, header, footer, nav
   ============================================================ */

/* ── Reset ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

/* ── Design tokens ── */
:root {
  --bg:        #F8F8F5;
  --surface:   #EFEFEB;
  --border:    #DDDDD8;
  --muted:     #888884;
  --text:      #1A1A1A;
  --accent:    #2563EB;
  --accent-bg: #EEF3FF;
  --mono:      'JetBrains Mono', monospace;
  --sans:      'Inter', sans-serif;
  --radius:    4px;
}

/* ── Base ── */
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.65;
  min-height: 100vh;
}

a { color: inherit; text-decoration: none; }

/* ── Site wrapper ── */
.site-wrap {
  max-width: 720px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ── Header ── */
header {
  padding: 48px 0 36px;
  border-bottom: 1px solid var(--border);
  margin-bottom: 40px;
}

.site-title {
  font-family: var(--mono);
  font-weight: 700;
  letter-spacing: -0.5px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 2px;
  margin-bottom: 8px;
  text-decoration: none;
}

.site-title .prompt { color: var(--accent); }

.cursor {
  display: inline-block;
  width: 10px;
  height: 18px;
  background: var(--accent);
  margin-left: 3px;
  vertical-align: middle;
  animation: blink 1.1s step-start infinite;
}

@keyframes blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0; }
}

.site-desc {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
  letter-spacing: 0.02em;
}

nav {
  margin-top: 20px;
  display: flex;
  gap: 20px;
  align-items: center;
}

nav a {
  font-family: var(--mono);
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: color 0.15s;
}

nav a:hover,
nav a.active { color: var(--accent); }

/* ── Footer ── */
footer {
  margin-top: 72px;
  padding: 32px 0 40px;
  border-top: 1px solid var(--border);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer-brand {
  font-family: var(--mono);
  font-size: 12px;
  color: var(--muted);
}

.footer-brand span { color: var(--accent); }

.footer-links {
  display: flex;
  gap: 16px;
}

.footer-links a {
  font-family: var(--mono);
  font-size: 11px;
  color: var(--muted);
  transition: color 0.15s;
}

.footer-links a:hover { color: var(--text); }

/* ── Responsive ── */
@media (max-width: 520px) {
  header { padding: 32px 0 24px; }
  footer { flex-direction: column; gap: 16px; text-align: center; }
}

@media (prefers-reduced-motion: reduce) {
  .cursor { animation: none; opacity: 1; }
}
