/* Anthonny's site — dark, minimal, readable */

:root {
  --bg: #0F0F0F;
  --bg-raised: #181818;
  --ink: #E8E0D5;
  --muted: #8A8580;
  --accent: #E85D04;
  --border: rgba(232, 224, 213, 0.10);
}

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

html {
  font-size: 15px;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  background: var(--bg);
  color: var(--ink);
  line-height: 1.65;
  padding: 0;
}

/* Global image safety */
img, picture {
  max-width: 100%;
  height: auto;
  display: block;
}

a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 0.15em;
}

a:hover {
  color: #FF7B2B;
}

/* Layout */
.container {
  max-width: 640px;
  margin: 0 auto;
  padding: 0 1.25rem;
}

/* Nav */
nav {
  padding: 1.25rem 0;
  border-bottom: 1px solid var(--border);
}

nav .container {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
}

.nav-logo {
  font-weight: 500;
  font-size: 1rem;
  color: var(--ink);
  text-decoration: none;
}

.nav-logo:hover {
  color: var(--accent);
}

.nav-links {
  display: flex;
  gap: 1.25rem;
  list-style: none;
}

.nav-links a {
  font-size: 0.85rem;
  color: var(--muted);
  text-decoration: none;
}

.nav-links a:hover {
  color: var(--ink);
  text-decoration: underline;
}

/* Header */
.site-header {
  padding: 2.5rem 0 2rem;
}

.site-header h1 {
  font-size: 1.5rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  letter-spacing: -0.01em;
  color: var(--ink);
}

.site-header-tagline {
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: 0.75rem;
  max-width: 50ch;
}

.site-header-note {
  font-size: 0.85rem;
  color: var(--muted);
  max-width: 55ch;
  line-height: 1.6;
}

/* Projects — just a list */
.project-entry {
  display: block;
  text-decoration: none;
  color: inherit;
  margin-bottom: 3rem;
}

.project-entry:hover .project-title {
  color: var(--accent);
}

.project-entry img {
  width: 100%;
  border-radius: 3px;
  margin-bottom: 0.75rem;
  border: 1px solid var(--border);
}

.project-meta {
  font-size: 0.8rem;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.project-meta span + span::before {
  content: " · ";
}

.project-title {
  font-size: 1.15rem;
  font-weight: 600;
  margin-bottom: 0.35rem;
  color: var(--ink);
  text-decoration: none;
  transition: color 0.15s;
}

.project-desc {
  font-size: 0.9rem;
  color: var(--muted);
  line-height: 1.5;
}

/* Divider between entries */
.project-divider {
  border: none;
  border-top: 1px solid var(--border);
  margin: 2.5rem 0;
}

/* Footer */
.site-footer {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
  margin-top: 1rem;
}

.site-footer p {
  font-size: 0.85rem;
  color: var(--muted);
}

/* ============================================================
   PROJECT PAGE
   ============================================================ */

.project-page-header {
  padding: 1.5rem 0;
}

.project-page-header h1 {
  font-size: 1.6rem;
  font-weight: 600;
  margin-bottom: 0.4rem;
  color: var(--ink);
}

.project-page-meta {
  font-size: 0.8rem;
  color: var(--muted);
}

.project-page-meta span + span::before {
  content: " · ";
}

.project-section {
  padding: 1.5rem 0;
}

.project-section h2 {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--muted);
  margin-bottom: 1rem;
}

.project-section p {
  font-size: 0.95rem;
  color: var(--ink);
  margin-bottom: 1rem;
  max-width: 60ch;
}

.project-section p:last-child {
  margin-bottom: 0;
}

.project-image {
  width: 100%;
  border-radius: 3px;
  border: 1px solid var(--border);
  margin: 1rem 0;
}

.project-image-caption {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: -0.5rem;
  margin-bottom: 1rem;
}

/* Math */
.math-block {
  background: var(--bg-raised);
  border: 1px solid var(--border);
  border-radius: 3px;
  padding: 1.25rem;
  margin: 1rem 0;
  overflow-x: auto;
}

.math-block .mjx-chtml {
  font-size: 1em !important;
  color: var(--ink);
}

mjx-container {
  color: var(--ink) !important;
}

/* Build steps */
.build-step {
  margin-bottom: 1.5rem;
}

.build-step-number {
  font-size: 0.75rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.2rem;
}

.build-step h4 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 0.3rem;
  color: var(--ink);
}

.build-step p {
  font-size: 0.9rem;
  color: var(--muted);
}

/* Result */
.result-box {
  background: var(--bg-raised);
  border: 1px solid var(--accent);
  border-radius: 3px;
  padding: 1.25rem;
  margin: 1rem 0;
}

.result-box h3 {
  font-size: 1rem;
  font-weight: 600;
  color: var(--accent);
  margin-bottom: 0.75rem;
}

.result-box p {
  font-size: 0.9rem;
  color: var(--ink);
  margin-bottom: 0.75rem;
}

.result-box p:last-child {
  margin-bottom: 0;
}

/* Back link */
.back-link {
  display: inline-block;
  margin-top: 2rem;
  font-size: 0.85rem;
}

/* Mobile */
@media (max-width: 480px) {
  .container {
    padding: 0 1rem;
  }

  .site-header {
    padding: 2rem 0 1rem;
  }

  .site-header h1 {
    font-size: 1.3rem;
  }

  .project-page-header h1 {
    font-size: 1.4rem;
  }
}
