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

:root {
  --bg: #fffff8;
  --text: #000000;
  --muted: #555;
  --border: #ddd;
  --nav-height: 56px;
}

html {
  scroll-behavior: smooth;
}

body {
  background-color: var(--bg);
  color: var(--text);
  font-family: 'EB Garamond', Georgia, serif;
  font-size: 1.125rem;
  line-height: 1.7;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ── HEADER ── */
header {
  position: sticky;
  top: 0;
  z-index: 100;
  background-color: var(--bg);
  border-bottom: 1px solid var(--border);
  height: var(--nav-height);
  display: flex;
  align-items: center;
  padding: 0 2rem;
  justify-content: space-between;
}

.nav-logo {
  font-family: 'DM Mono', monospace;
  font-weight: 500;
  font-size: 1rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.02em;
}

nav {
  display: flex;
  align-items: center;
  gap: 2rem;
}

nav a {
  font-family: 'DM Mono', monospace;
  font-size: 0.82rem;
  font-weight: 400;
  color: var(--text);
  text-decoration: none;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  transition: opacity 0.15s;
}

nav a:hover,
nav a.active {
  opacity: 0.4;
}

.nav-icons {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.nav-icons a {
  display: flex;
  align-items: center;
  color: var(--text);
  transition: opacity 0.15s;
}

.nav-icons a:hover {
  opacity: 0.4;
}

.nav-icons svg {
  width: 20px;
  height: 20px;
  fill: var(--text);
}

/* ── HERO (home page only) ── */
.hero {
  max-width: 720px;
  margin: 0 auto;
  padding: 7rem 2rem 5rem;
  flex: 1;
}

.hero h1 {
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 400;
  line-height: 1.15;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
}

.hero h2 {
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 400;
  font-style: italic;
  color: var(--muted);
  margin-bottom: 2rem;
}

.hero p {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 580px;
}

/* ── PAGE CONTENT (inner pages) ── */
.page-content {
  max-width: 720px;
  margin: 0 auto;
  padding: 4rem 2rem;
  flex: 1;
  width: 100%;
}

.page-content h2 {
  font-size: clamp(1.8rem, 4vw, 2.6rem);
  font-weight: 400;
  margin-bottom: 2.5rem;
  letter-spacing: -0.01em;
}

.section-label {
  font-family: 'DM Mono', monospace;
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 2rem;
}

/* ── PROJECTS ── */
.project-list {
  display: flex;
  flex-direction: column;
}

.project {
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: start;
  gap: 1rem;
  padding: 1.75rem 0;
  border-bottom: 1px solid var(--border);
}

.project:first-child {
  border-top: 1px solid var(--border);
}

.project-title {
  font-size: 1.2rem;
  font-weight: 500;
  margin-bottom: 0.25rem;
}

.project-desc {
  font-size: 1rem;
  color: var(--muted);
  font-style: italic;
}

.project-link {
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  color: var(--text);
  text-decoration: none;
  border: 1px solid var(--border);
  padding: 0.3rem 0.7rem;
  white-space: nowrap;
  transition: background 0.15s, color 0.15s;
  margin-top: 0.2rem;
}

.project-link:hover {
  background: var(--text);
  color: var(--bg);
}

/* ── ABOUT ── */
.about-text p {
  font-size: 1.1rem;
  color: var(--muted);
  max-width: 580px;
}

.about-text p + p {
  margin-top: 1.25rem;
}

/* ── CONTACT ── */
.contact-links {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-links a {
  font-family: 'DM Mono', monospace;
  font-size: 0.9rem;
  color: var(--text);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  transition: opacity 0.15s;
}

.contact-links a:hover {
  opacity: 0.4;
}

.contact-links svg {
  width: 16px;
  height: 16px;
  fill: currentColor;
  flex-shrink: 0;
}

/* ── FOOTER ── */
footer {
  max-width: 720px;
  margin: 0 auto;
  padding: 1.5rem 2rem;
  border-top: 1px solid var(--border);
  width: 100%;
}

footer p {
  font-family: 'DM Mono', monospace;
  font-size: 0.75rem;
  color: var(--muted);
  letter-spacing: 0.04em;
}

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(16px); }
  to   { opacity: 1; transform: translateY(0); }
}

.hero h1 { animation: fadeUp 0.55s ease both; }
.hero h2 { animation: fadeUp 0.55s ease both; animation-delay: 0.1s; }
.hero p  { animation: fadeUp 0.55s ease both; animation-delay: 0.2s; }

.page-content { animation: fadeUp 0.45s ease both; }
