/* ========================================
   TOKENS.CSS
   Design tokens, reset, typography base,
   global texture overlay.
   Single source of truth for all variables.
   ======================================== */

/* === DESIGN TOKENS === */
:root {
  /* Colors */
  --color-bg:           #0F0F0E;
  --color-surface:      #1A1A19;
  --color-border:       #2A2A28;
  --color-text:         #F0EDE6;
  --color-text-dim:     #8A8680;
  --color-text-muted:   #5A5752;
  --color-accent:       #1D9E8D;
  --color-accent-hover: #24B8A5;

  /* Typography */
  --font-display: 'Space Grotesk', sans-serif;
  --font-body:    'Lato', sans-serif;

  /* Fluid type scale (mobile-first) */
  --text-hero:   clamp(2.75rem, 8vw, 7rem);
  --text-h1:     clamp(2rem, 5vw, 4.5rem);
  --text-h2:     clamp(1.75rem, 4vw, 3.5rem);
  --text-h3:     clamp(1.125rem, 2vw, 1.75rem);
  --text-body:   clamp(1rem, 1.2vw, 1.125rem);
  --text-small:  clamp(0.8rem, 1vw, 0.875rem);
  --text-label:  0.75rem;

  /* Spacing */
  --space-xs:      0.5rem;
  --space-sm:      1rem;
  --space-md:      2rem;
  --space-lg:      4rem;
  --space-xl:      8rem;
  --space-section: clamp(6rem, 12vh, 10rem);

  /* Layout */
  --container-max: 1280px;
  --container-pad: clamp(1.25rem, 4vw, 3rem);
  --grid-cols:     12;
  --grid-gap:      clamp(1rem, 2vw, 2rem);

  /* Motion */
  --ease-out:    cubic-bezier(0.16, 1, 0.3, 1);
  --ease-in-out: cubic-bezier(0.65, 0, 0.35, 1);
  --dur-fast:    0.2s;
  --dur-normal:  0.4s;
  --dur-slow:    0.8s;

  /* Nav */
  --nav-height: 3.5rem;
}

@media (min-width: 769px) {
  :root {
    --nav-height: 4rem;
  }
}


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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
}

body {
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  color: var(--color-text);
  background-color: var(--color-bg);
  overflow-x: hidden;
}

html.lenis,
html.lenis body {
  height: auto;
}

a {
  color: var(--color-accent);
  text-decoration: none;
  transition: color var(--dur-fast);
}

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

img {
  max-width: 100%;
  height: auto;
  display: block;
}

::selection {
  background: var(--color-accent);
  color: var(--color-bg);
}

:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 2px;
}


/* === TYPOGRAPHY BASE === */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  line-height: 1.1;
  color: var(--color-text);
}

p {
  max-width: 65ch;
}


/* === GLOBAL TEXTURE (concrete noise overlay) === */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none;
  z-index: 9999;
  mix-blend-mode: overlay;
  opacity: 0.6;
}
