/* =============================================
   BASE STYLES & DESIGN SYSTEM
   Thomas [Last Name] Portfolio
   ============================================= */

@import url('https://fonts.googleapis.com/css2?family=Cormorant+Garamond:ital,wght@0,300;0,400;0,500;1,300;1,400&family=IBM+Plex+Mono:wght@300;400&display=swap');

/* --- CSS Variables --- */
:root {
  --bg: #f7f6f2;          /* warm off-white */
  --ink: #171714;          /* near-black */
  --muted: #8a8a84;        /* secondary text */
  --rule: #d9d8d3;         /* dividers */
  --accent: #171714;       /* same as ink for restraint */

  --font-display: 'Cormorant Garamond', Georgia, serif;
  --font-mono: 'IBM Plex Mono', 'Courier New', monospace;

  --space-xs: 0.5rem;
  --space-sm: 1rem;
  --space-md: 2rem;
  --space-lg: 4rem;
  --space-xl: 8rem;

  --max-width: 860px;
  --nav-height: 60px;
}

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

html {
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}

body {
  background-color: var(--bg);
  color: var(--ink);
  font-family: var(--font-mono);
  font-weight: 300;
  line-height: 1.7;
  min-height: 100vh;
}

/* --- Typography --- */
h1, h2, h3 {
  font-family: var(--font-display);
  font-weight: 300;
  letter-spacing: 0.01em;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); line-height: 1.1; }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); line-height: 1.2; }
h3 { font-size: 1.2rem; }

p { font-size: 0.85rem; line-height: 1.9; color: var(--ink); }

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

/* --- Navigation --- */
nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 var(--space-lg);
  background: var(--bg);
  z-index: 100;
  /* subtle bottom border on scroll — handled via JS */
}

nav .site-name {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 400;
  letter-spacing: 0.02em;
}

nav .nav-links {
  display: flex;
  gap: var(--space-md);
  list-style: none;
  font-size: 0.7rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

nav .nav-links a {
  color: var(--muted);
  transition: color 0.2s ease;
}

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

/* --- Page wrapper --- */
.page {
  padding-top: var(--nav-height);
}

/* --- Horizontal rule --- */
hr {
  border: none;
  border-top: 1px solid var(--rule);
  margin: var(--space-lg) 0;
}

/* --- Footer --- */
footer {
  padding: var(--space-lg);
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  color: var(--muted);
  display: flex;
  justify-content: space-between;
  align-items: flex-end;
  border-top: 1px solid var(--rule);
  margin-top: var(--space-xl);
}

footer a {
  color: var(--muted);
  transition: color 0.2s;
}

footer a:hover {
  color: var(--ink);
}

/* --- Scrollbar (cosmetic) --- */
::-webkit-scrollbar { width: 4px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--rule); }
