/* ═══════════════════════════════════════════════════════════════════
   base.css — shared design tokens
   
   Inherits the visual language of bower.im:
   - Lora (serif) for body text
   - Alata (sans) for primary/display
   - Roboto (sans) as default fallback
   - Cool stone-grey background, charcoal text, neutral project defaults
   ═══════════════════════════════════════════════════════════════════ */

:root {
  /* Typography */
  --font-body:    "Lora", Georgia, serif;
  --font-display: "Alata", "Helvetica Neue", sans-serif;
  --font-default: "Roboto", -apple-system, BlinkMacSystemFont, sans-serif;

  /* Light palette (matches bower.im) */
  --bg:               #eaedf0;
  --bg-secondary:     #f8f9fa;
  --text:             #343a40;
  --text-secondary:   #6c757d;
  --primary:          #007bff;
  --border:           #d6dadf;

  /* Functional */
  --radius:    8px;
  --radius-lg: 16px;
  --shadow:    0 1px 3px rgba(0, 0, 0, 0.04), 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 4px 12px rgba(0, 0, 0, 0.05), 0 12px 32px rgba(0, 0, 0, 0.08);

  /* Type scale */
  --fs-display: clamp(40px, 8vw, 64px);
  --fs-h1:      clamp(28px, 4vw, 36px);
  --fs-h2:      clamp(20px, 3vw, 24px);
  --fs-body:    16px;
  --fs-small:   13px;
  --fs-tiny:    11px;
}

/* Reset */
*, *::before, *::after { box-sizing: border-box; }
html, body, h1, h2, h3, p, ul, figure { margin: 0; padding: 0; }
ul { list-style: none; }
img { max-width: 100%; height: auto; display: block; }

/* Base */
html {
  -webkit-text-size-adjust: 100%;
  -webkit-tap-highlight-color: transparent;
}
body {
  font-family: var(--font-body);
  font-size: var(--fs-body);
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: opacity 0.15s ease;
}
a:hover { opacity: 0.75; }

/* Skip-to-content link for keyboard users */
.skip-link {
  position: absolute;
  top: -100px;
  left: 8px;
  background: var(--text);
  color: var(--bg);
  padding: 8px 16px;
  border-radius: var(--radius);
  z-index: 999;
  font-family: var(--font-default);
  font-size: var(--fs-small);
}
.skip-link:focus { top: 8px; }

/* Animations honour reduced-motion */
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}
