@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600&family=Merriweather:wght@300;400;700&family=Fira+Code:wght@400&display=swap');

:root {
  /* Professional Color Palette */
  --primary-color: #0f4c81; /* Classic Navy Blue */
  --secondary-color: #475569; /* Slate 600 */
  --bg-color: #ffffff;
  --bg-alt: #f8fafc; /* Very light slate for contrast */
  --text-main: #1e293b; /* Slate 800 */
  --text-muted: #64748b; /* Slate 500 */
  --border-color: #e2e8f0; /* Slate 200 */
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--text-main);
  background-color: var(--bg-color);
  line-height: 1.6;
}

/* Typography & Headings */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Merriweather', serif; /* Professional serif for headings */
  color: var(--primary-color);
  margin-top: 2rem;
  margin-bottom: 1rem;
}

h1.title {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary-color);
  border-bottom: 2px solid var(--primary-color);
  padding-bottom: 0.5rem;
  margin-bottom: 2rem;
}

/* Sidebar Styling */
#quarto-sidebar {
  background-color: var(--bg-alt);
  border-right: 1px solid var(--border-color);
}

.sidebar-title a, .sidebar-item-text {
  font-weight: 500;
  color: var(--secondary-color);
  transition: color 0.2s ease;
}

.sidebar-item-container:hover .sidebar-item-text {
  color: var(--primary-color) !important;
}

/* Links */
a {
  color: #2563eb;
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

/* Main Content Area */
main.content {
  background: #ffffff;
  padding: 2rem;
  max-width: 900px;
  margin: 0 auto;
}

/* Images */
img {
  border: 1px solid var(--border-color);
  margin-top: 1.5rem;
  margin-bottom: 1.5rem;
  max-width: 100%;
}

/* Professional Tables */
table {
  width: 100%;
  border-collapse: collapse;
  margin: 2rem 0;
  font-size: 0.95rem;
}

th {
  background-color: var(--bg-alt);
  color: var(--primary-color);
  font-weight: 600;
  padding: 0.75rem 1rem;
  text-align: left;
  border-top: 2px solid var(--primary-color);
  border-bottom: 1px solid var(--border-color);
  text-transform: uppercase;
  font-size: 0.85rem;
  letter-spacing: 0.02em;
}

td {
  padding: 0.75rem 1rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-main);
}

tr:nth-child(even) td {
  background-color: #fcfcfc;
}

tr:hover td {
  background-color: #f1f5f9;
}

/* Code Blocks */
pre, code {
  font-family: 'Fira Code', monospace;
  font-size: 0.9em;
}

/* Use a light background for code blocks so Quarto's default dark syntax highlighting is visible */
div.sourceCode {
  background-color: var(--bg-alt);
  border: 1px solid var(--border-color);
  border-radius: 4px;
  margin: 1.5rem 0;
}

div.sourceCode pre {
  color: var(--text-main);
}

/* Buttons */
.btn {
  background-color: var(--bg-alt);
  border: 1px solid var(--border-color);
  color: var(--text-main);
  border-radius: 4px;
  padding: 0.5rem 1rem;
  font-weight: 500;
}

.btn:hover {
  background-color: #e2e8f0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
  main.content {
    padding: 1rem;
  }
}
