/* Reset some default styles */
* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', 'Segoe UI', 'Helvetica Neue', sans-serif;
  line-height: 1.75;
  font-size: 1rem;
  color: #1f2937;
  background-color: #f9fafb;
  padding: 2rem;
  max-width: 800px;
  margin: auto;
}

/* Headers */
h1, h2, h3, h4, h5, h6 {
  color: #111827;
  margin-top: 2rem;
  margin-bottom: 1rem;
  font-weight: 600;
  line-height: 1.2;
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1rem; }
h6 { font-size: 0.875rem; }

/* Paragraphs */
p {
  margin-bottom: 1.5rem;
}

/* Links */
a {
  color: #3b82f6;
  text-decoration: none;
}
a:hover {
  text-decoration: underline;
}

/* Lists */
ul, ol {
  padding-left: 2rem;
  margin-bottom: 1.5rem;
}

li {
  margin-bottom: 0.5rem;
}

/* Code blocks */
pre, code {
  font-family: 'Fira Code', 'Courier New', monospace;
  background-color: #f3f4f6;
  border-radius: 5px;
  padding: 0.25rem 0.5rem;
}

pre {
  padding: 1rem;
  overflow-x: auto;
  margin-bottom: 1.5rem;
}

code {
  font-size: 0.9rem;
}

/* Blockquotes */
blockquote {
  border-left: 4px solid #3b82f6;
  padding-left: 1rem;
  color: #374151;
  font-style: italic;
  margin: 1.5rem 0;
}

/* Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin-bottom: 1.5rem;
}
th, td {
  border: 1px solid #d1d5db;
  padding: 0.75rem;
  text-align: left;
}
th {
  background-color: #e5e7eb;
  font-weight: 600;
}

/* Images */
img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

/* Responsive design */
@media (max-width: 600px) {
  body {
    padding: 1rem;
    font-size: 0.95rem;
  }

  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.25rem; }
}

/* Org-mode specific styling (optional) */
.todo {
  color: #ef4444;
  font-weight: bold;
}
.done {
  color: #10b981;
  font-weight: bold;
}
.tag {
  font-size: 0.8rem;
  background: #e0f2fe;
  color: #0369a1;
  border-radius: 4px;
  padding: 2px 6px;
  margin-left: 0.5rem;
}

/* Header navigation */
.topnav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.2rem 0;
  border-top: 1px solid #d1d5db;
  border-bottom: 1px solid #d1d5db;
  padding-bottom: 1px;
  margin-bottom: 20px;
}

.topnav h2 {
  margin: 0;
  font-size: 1.75rem;
  font-weight: 700;
  font-style: italic;
}

.topnav h2 a {
  text-decoration: none;
  color: #111827;
}

.topnav nav {
  display: flex;
  gap: 1rem;
}

.topnav nav a {
  text-decoration: none;
  font-weight: 600;
  font-style: italic;
  color: #3b82f6;
  transition: color 0.2s;
}

.topnav nav a:hover {
  color: #2563eb;
}

/* Optional: horizontal line styling */
.divider {
  margin-top: 0;
  border-top: 1px solid #d1d5db;
}

/* Responsive tweak: stack on small screens */
@media (max-width: 600px) {
  .topnav {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }

  .topnav nav {
    flex-wrap: wrap;
    gap: 0.5rem 1rem;
  }
}

.about {
  border-top: 1px solid #d1d5db;
  border-bottom: 1px solid #d1d5db;
  padding: 1.5rem 0;
  margin: 2rem 0;
}

.about p {
  margin: 0 0 1rem 0;
  font-size: 1.1rem;
  line-height: 1.6;
  color: #374151;
}

pre.src {
    background-color: #f8f9fa; /* Light background */
    border: 1px solid #d0d7de; /* Light gray border */
    padding: 10px;
    overflow: auto;
    font-family: monospace;
    font-size: 0.95em;
}

.org-src-container {
    background-color: #f8f9fa;
}

pre span.org-builtin {
    color: #531ab6; /* purple */
    font-weight: bold;
}
pre span.org-string {
    color: #20794d; /* dark green */
}
pre span.org-keyword {
    color: #0031a9; /* strong blue */
    font-weight: bold;
}
pre span.org-variable-name {
    color: #531ab6; /* purple */
}
pre span.org-function-name {
    color: #005f88; /* deep cyan */
}
pre span.org-type {
    color: #531ab6; /* purple */
}
pre span.org-preprocessor {
    color: #5f5f5f;
    font-weight: bold;
}
pre span.org-constant {
    color: #a60000; /* strong red */
}
pre span.org-comment-delimiter,
pre span.org-comment {
    color: #7c7c7c;
    font-style: italic;
}
pre span.org-outshine-level-1,
pre span.org-outshine-level-2,
pre span.org-outshine-level-3,
pre span.org-outshine-level-4,
pre span.org-outshine-level-5,
pre span.org-outshine-level-6,
pre span.org-outshine-level-7,
pre span.org-outshine-level-8,
pre span.org-outshine-level-9 {
    color: #999999;
    font-style: italic;
}
pre span.org-rainbow-delimiters-depth-1  { color: #005f88; }
pre span.org-rainbow-delimiters-depth-2  { color: #20794d; }
pre span.org-rainbow-delimiters-depth-3  { color: #531ab6; }
pre span.org-rainbow-delimiters-depth-4  { color: #a60000; }
pre span.org-rainbow-delimiters-depth-5  { color: #0031a9; }
pre span.org-rainbow-delimiters-depth-6  { color: #5f5f5f; }
pre span.org-rainbow-delimiters-depth-7  { color: #531ab6; }
pre span.org-rainbow-delimiters-depth-8  { color: #20794d; }
pre span.org-rainbow-delimiters-depth-9  { color: #005f88; }
pre span.org-sh-quoted-exec {
    color: #a60000; /* deep red */
}
