/* NEUPL Base Styles */

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

html {
  -webkit-text-size-adjust: 100%;
  font-feature-settings: "ss01", "tnum";
}

body {
  font-family: var(--font);
  font-size: var(--text-base);
  line-height: var(--leading);
  color: var(--text);
  background: var(--bg);
  letter-spacing: -0.01em;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: inherit;
  text-decoration: none;
}
a:hover { text-decoration: underline; text-underline-offset: 3px; }

button, input, select, textarea {
  font: inherit;
  color: inherit;
}

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

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: var(--space-6) 0;
}

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

/* Layout */
.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.container {
  width: 100%;
  max-width: var(--container);
  margin: 0 auto;
  padding: 0 var(--space-5);
}

@media (max-width: 640px) {
  .container { padding: 0 var(--space-4); }
}

/* Header */
.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 56px;
}
.brand-logo {
  font-weight: 600;
  font-size: var(--text-lg);
  letter-spacing: -0.02em;
}

/* Nav */
.nav {
  display: flex;
  gap: var(--space-5);
  align-items: center;
}
.nav a {
  font-size: var(--text-sm);
  color: var(--text-muted);
  padding: var(--space-2) 0;
}
.nav a:hover { color: var(--text); text-decoration: none; }
.nav a.active { color: var(--text); }

.nav-user {
  display: flex;
  gap: var(--space-3);
  align-items: center;
  font-size: var(--text-sm);
  color: var(--text-muted);
}

/* Main */
.main {
  flex: 1;
  padding: var(--space-7) 0 var(--space-8);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: var(--space-5) 0;
  font-size: var(--text-xs);
  color: var(--text-faint);
  text-align: center;
}

/* Typography utilities */
.h1 { font-size: var(--text-3xl); font-weight: 700; letter-spacing: -0.02em; }
.h2 { font-size: var(--text-xl); font-weight: 600; letter-spacing: -0.01em; }
.h3 { font-size: var(--text-lg); font-weight: 600; }
.muted { color: var(--text-muted); }
.faint { color: var(--text-faint); }
.small { font-size: var(--text-sm); }

.stack > * + * { margin-top: var(--space-4); }
.stack-lg > * + * { margin-top: var(--space-6); }
.stack-xl > * + * { margin-top: var(--space-7); }

/* Sections */
.section-title {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: var(--space-4);
  padding-bottom: var(--space-2);
  border-bottom: 1px solid var(--border);
}
.section-title h2 {
  font-size: var(--text-lg);
  font-weight: 600;
}
