/* incendi.com - minimal stylesheet */

:root {
  --color-bg:        #fafaf8;
  --color-text:      #1a1a1a;
  --color-muted:     #6b6b6b;
  --color-border:    #ddd;
  --color-accent:    #c94a00;
  --color-accent-bg: #fff4ef;
  --font-sans: system-ui, -apple-system, "Segoe UI", Helvetica, Arial, sans-serif;
  --font-mono: "SFMono-Regular", Consolas, "Liberation Mono", Menlo, monospace;
  --max-width: 780px;
}

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

html {
  font-size: 18px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-sans);
  line-height: 1.7;
}

a {
  color: var(--color-accent);
  text-decoration: underline;
  text-underline-offset: 3px;
}

a:hover {
  color: #8c3200;
}

/* ── Layout ──────────────────────────────────────── */

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* ── Header / Nav ────────────────────────────────── */

header {
  border-bottom: 1px solid var(--color-border);
  padding: 1rem 0;
}

header .container {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.site-logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: var(--color-text);
  font-weight: 700;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

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

.site-logo img,
.site-logo svg {
  height: 28px;
  width: auto;
}

nav {
  margin-left: auto;
}

nav a {
  margin-left: 1.5rem;
  text-decoration: none;
  color: var(--color-muted);
  font-size: 0.95rem;
}

nav a:hover,
nav a[aria-current="page"] {
  color: var(--color-text);
}

/* ── Hero ────────────────────────────────────────── */

.hero {
  padding: 4rem 0 3rem;
  border-bottom: 1px solid var(--color-border);
}

.hero h1 {
  font-size: 2.2rem;
  font-weight: 800;
  line-height: 1.2;
  margin: 0 0 1rem;
  letter-spacing: -0.02em;
}

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

/* ── Sections ────────────────────────────────────── */

.section {
  padding: 3rem 0;
  border-bottom: 1px solid var(--color-border);
}

.section:last-of-type {
  border-bottom: none;
}

.section h2 {
  font-size: 1.4rem;
  font-weight: 700;
  margin: 0 0 1rem;
  letter-spacing: -0.01em;
}

.section p {
  margin: 0 0 1rem;
  color: var(--color-text);
}

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

/* ── Project card ────────────────────────────────── */

.project-card {
  background: var(--color-accent-bg);
  border: 1px solid #e8c8bc;
  border-radius: 6px;
  padding: 1.5rem;
  margin-top: 1.5rem;
}

.project-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
  font-weight: 700;
}

.project-card p {
  margin: 0 0 1rem;
  font-size: 0.95rem;
  color: var(--color-muted);
}

.project-card .links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
  font-size: 0.9rem;
}

/* ── Blog listing ────────────────────────────────── */

.post-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.post-list li {
  padding: 1.5rem 0;
  border-bottom: 1px solid var(--color-border);
}

.post-list li:first-child {
  padding-top: 0;
}

.post-list li:last-child {
  border-bottom: none;
}

.post-list .post-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
}

.post-list .post-meta {
  font-size: 0.85rem;
  color: var(--color-muted);
  margin: 0 0 0.4rem;
  font-family: var(--font-mono);
}

.post-list .post-desc {
  margin: 0;
  color: var(--color-muted);
  font-size: 0.95rem;
}

/* ── Blog post (article) ─────────────────────────── */

.post-header {
  padding: 3rem 0 2rem;
  border-bottom: 1px solid var(--color-border);
}

.post-header h1 {
  font-size: 2rem;
  font-weight: 800;
  line-height: 1.25;
  margin: 0 0 0.5rem;
  letter-spacing: -0.02em;
}

.post-header .post-meta {
  color: var(--color-muted);
  font-size: 0.85rem;
  font-family: var(--font-mono);
}

.post-body {
  padding: 2.5rem 0;
}

.post-body h2 {
  font-size: 1.35rem;
  font-weight: 700;
  margin: 2rem 0 0.75rem;
}

.post-body h3 {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 1.5rem 0 0.5rem;
}

.post-body p {
  margin: 0 0 1rem;
}

.post-body ul,
.post-body ol {
  margin: 0 0 1rem;
  padding-left: 1.5rem;
}

.post-body li {
  margin-bottom: 0.25rem;
}

.post-body code {
  font-family: var(--font-mono);
  font-size: 0.875em;
  background: #f0efed;
  padding: 0.1em 0.35em;
  border-radius: 3px;
}

.post-body pre {
  background: #1e1e1e;
  color: #d4d4d4;
  padding: 1.25rem 1.5rem;
  border-radius: 6px;
  overflow-x: auto;
  font-size: 0.875rem;
  line-height: 1.6;
  margin: 0 0 1.5rem;
}

.post-body pre code {
  background: none;
  padding: 0;
  color: inherit;
  font-size: inherit;
}

.post-body blockquote {
  border-left: 3px solid var(--color-accent);
  margin: 0 0 1rem;
  padding: 0.25rem 0 0.25rem 1.25rem;
  color: var(--color-muted);
  font-style: italic;
}

.back-link {
  display: inline-block;
  font-size: 0.9rem;
  color: var(--color-muted);
  text-decoration: none;
  margin-top: 0.5rem;
}

.back-link:hover {
  color: var(--color-text);
}

/* ── Footer ──────────────────────────────────────── */

footer {
  border-top: 1px solid var(--color-border);
  padding: 2rem 0;
  margin-top: 2rem;
  font-size: 0.85rem;
  color: var(--color-muted);
}

footer .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.5rem;
}

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

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

/* ── Responsive ──────────────────────────────────── */

@media (max-width: 600px) {
  html {
    font-size: 16px;
  }

  .hero h1 {
    font-size: 1.7rem;
  }

  footer .container {
    flex-direction: column;
    align-items: flex-start;
  }
}
