/* ============================================================
   ARAV JAIN — PORTFOLIO
   tokens.css — design tokens, resets, base typography
   ============================================================ */

:root {
  /* ── Color tokens ───────────────────────────────────── */
  --ink: #0b0e11;
  --ink-soft: #11151b;
  --panel: #161b22;
  --panel-raised: #1b2128;
  --paper: #f3f1ea;
  --paper-dim: #c9c6bc;
  --signal: #3ddc8a;
  --signal-dim: #2a9c63;
  --signal-glow: rgba(61, 220, 138, 0.35);
  --instrument: #8a93a6;
  --instrument-dim: #5b6272;
  --hairline: rgba(138, 147, 166, 0.18);
  --hairline-bright: rgba(138, 147, 166, 0.32);
  --amber: #e0a96d;

  /* ── Type tokens ────────────────────────────────────── */
  --font-display: "Fraunces", "Times New Roman", serif;
  --font-mono: "IBM Plex Mono", ui-monospace, "SF Mono", monospace;
  --font-body: "Inter", -apple-system, "Segoe UI", sans-serif;

  /* ── Layout tokens ──────────────────────────────────── */
  --rail-x: 28px;
  --content-max: 1180px;
  --edge: clamp(20px, 5vw, 64px);
  --section-gap: clamp(96px, 14vw, 180px);

  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --ease-spring: cubic-bezier(0.34, 1.56, 0.64, 1);
}

@media (max-width: 720px) {
  :root {
    --rail-x: 16px;
  }
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

body {
  margin: 0;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

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

a {
  color: inherit;
}

ul,
ol {
  margin: 0;
  padding: 0;
}

h1, h2, h3, h4, p {
  margin: 0;
}

button {
  font: inherit;
  color: inherit;
  background: none;
  border: none;
  cursor: pointer;
}

::selection {
  background: var(--signal);
  color: var(--ink);
}

:focus-visible {
  outline: 2px solid var(--signal);
  outline-offset: 3px;
  border-radius: 2px;
}

/* ── Texture: subtle grain so the near-black isn't flat ──── */
.grain {
  position: fixed;
  inset: 0;
  z-index: 2;
  pointer-events: none;
  opacity: 0.045;
  mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

/* ── Utility type classes ───────────────────────────────── */
.eyebrow {
  font-family: var(--font-mono);
  font-size: 12.5px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--signal);
}

.mono {
  font-family: var(--font-mono);
}

.section-head {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: clamp(40px, 6vw, 64px);
}

.section-head h2 {
  font-family: var(--font-display);
  font-weight: 600;
  font-size: clamp(2rem, 4.2vw, 3.1rem);
  letter-spacing: -0.01em;
  color: var(--paper);
}

.section-head .sub {
  font-family: var(--font-body);
  color: var(--instrument);
  font-size: 1rem;
  max-width: 540px;
}

.container {
  max-width: var(--content-max);
  margin: 0 auto;
  padding-left: var(--edge);
  padding-right: var(--edge);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
}
