/* ============================================
   Blog Stylesheet - System Fonts Only
   ============================================ */

/* Reset */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* Base */
html {
  font-size: 17px;
  scroll-behavior: smooth;
}

body {
  font-family: Georgia, 'Times New Roman', serif;
  font-weight: 400;
  color: #1d2433;
  background-color: #ffffff;
  line-height: 1.85;
  display: flex;
  flex-direction: column;
  align-items: center;
  padding: 3rem 1.5rem 5rem;
}

/* Top accent bar */
body::before {
  content: '';
  display: block;
  width: 100%;
  height: 5px;
  background: linear-gradient(90deg, #1a56db, #3b82f6);
  position: fixed;
  top: 0;
  left: 0;
  z-index: 100;
}

/* Content width */
h1, h2, h3, h4, h5, h6,
p, ul, ol, blockquote, table {
  max-width: 720px;
  width: 100%;
  margin-left: auto;
  margin-right: auto;
}

/* Headings */
h2 {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 1.85rem;
  font-weight: 700;
  line-height: 1.3;
  color: #0e1726;
  margin-top: 3.5rem;
  margin-bottom: 1rem;
}

h2:first-of-type {
  font-size: 2.2rem;
  margin-top: 2rem;
  padding-bottom: 1rem;
  border-bottom: 3px solid #f0f0f0;
}

h3 {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: 1.15rem;
  font-weight: 700;
  color: #1d2433;
  margin-top: 2.5rem;
  margin-bottom: 0.6rem;
}

/* Chapter banner h2 (those that follow a h3 or p) */
h3 + h2,
p + h2 {
  background: linear-gradient(135deg, #1a56db, #0e3fae);
  color: #ffffff;
  padding: 1.75rem 2rem;
  border-radius: 8px;
  margin-top: 4rem;
  margin-bottom: 2rem;
  font-size: 1.5rem;
  box-shadow: 0 4px 20px rgba(26, 86, 219, 0.2);
}

/* Body text */
p {
  font-size: 1rem;
  margin-bottom: 1.35rem;
  color: #2d3748;
}

h2:first-of-type + p {
  font-size: 1.08rem;
  color: #374151;
  line-height: 1.9;
}

/* Links */
a {
  color: #1a56db;
  text-decoration: none;
  border-bottom: 1px solid rgba(26, 86, 219, 0.3);
  transition: color 0.15s, border-color 0.15s;
}

a:hover {
  color: #1140a8;
  border-bottom-color: #1140a8;
}

/* Lists */
ul, ol {
  padding-left: 1.6rem;
  margin-top: 0.5rem;
  margin-bottom: 1.5rem;
}

ul li, ol li {
  margin-bottom: 0.5rem;
  line-height: 1.75;
  color: #2d3748;
}

ul li::marker {
  color: #1a56db;
}

ol li::marker {
  color: #1a56db;
  font-weight: 700;
}

strong {
  font-weight: 700;
  color: #0e1726;
}

/* Blockquote */
blockquote {
  max-width: 720px;
  margin: 2rem auto;
  padding: 1.25rem 1.5rem;
  background: #f0f5ff;
  border-left: 5px solid #1a56db;
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: #374151;
  font-size: 0.97rem;
  line-height: 1.85;
}

blockquote p {
  margin: 0;
  color: inherit;
}

/* Paragraph after blockquote (callout style) */
blockquote + p {
  background: #f0faf4;
  border-left: 4px solid #38a169;
  padding: 1rem 1.25rem;
  border-radius: 0 8px 8px 0;
  font-size: 0.93rem;
  color: #276749;
  margin-bottom: 1.5rem;
}

/* Table */
table {
  width: 100%;
  max-width: 720px;
  border-collapse: collapse;
  margin: 2rem auto;
  font-size: 0.9rem;
  border-radius: 8px;
  overflow: hidden;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.07), 0 0 0 1px #e2e8f0;
  background: #ffffff;
}

thead {
  background: #1a56db;
}

th {
  text-align: left;
  padding: 0.85rem 1rem;
  font-size: 0.78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  color: #ffffff;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
}

td {
  padding: 0.8rem 1rem;
  border-bottom: 1px solid #e2e8f0;
  color: #374151;
  vertical-align: top;
  line-height: 1.65;
}

tr:last-child td {
  border-bottom: none;
}

tbody tr:nth-child(even) td {
  background: #f8fafc;
}

tbody tr:hover td {
  background: #ebf0fa;
}

/* Responsive */
@media (max-width: 768px) {
  html {
    font-size: 15px;
  }

  h2:first-of-type {
    font-size: 1.75rem;
  }

  h3 + h2,
  p + h2 {
    font-size: 1.3rem;
    padding: 1.5rem;
  }

  th, td {
    padding: 0.65rem 0.75rem;
  }
}

@media (max-width: 480px) {
  h2:first-of-type {
    font-size: 1.5rem;
  }

  h3 + h2,
  p + h2 {
    font-size: 1.15rem;
  }
}
/* Hero Header */
#hero {
  width: 100%;
  background: linear-gradient(135deg, #1a56db, #0e3fae);
  text-align: center;
  padding: 5rem 2rem 4rem;
  margin-bottom: 3rem;
}

#hero-label {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  color: rgba(255, 255, 255, 0.75);
  text-transform: uppercase;
  margin-bottom: 1rem;
  max-width: none;
}

#hero h1 {
  font-family: Georgia, 'Times New Roman', serif;
  font-size: 3rem;
  font-weight: 700;
  color: #ffffff;
  line-height: 1.2;
  max-width: 720px;
  margin: 0 auto 1.25rem;
}

#hero-meta {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.7);
  max-width: none;
}

@media (max-width: 768px) {
  #hero h1 {
    font-size: 2rem;
  }
}
/* Top Bar */
#topbar {
  width: 100%;
  background: #ffffff;
  border-bottom: 1px solid #e2e8f0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 2.5rem;
  position: sticky;
  top: 0;
  z-index: 200;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
}

#topbar-brand {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: #1a56db;
  letter-spacing: -0.02em;
  text-transform: uppercase;
}

#topbar-nav {
  display: flex;
  gap: 2rem;
}

#topbar-nav a {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  color: #1d2433;
  border-bottom: none;
  text-decoration: none;
  transition: color 0.15s;
}

#topbar-nav a:hover {
  color: #1a56db;
}

/* Remove the old fixed accent bar since topbar replaces it */
body::before {
  display: none;
}

@media (max-width: 600px) {
  #topbar {
    padding: 0.75rem 1.25rem;
  }

  #topbar-nav {
    gap: 1.25rem;
  }

  #topbar-brand {
    font-size: 1rem;
  }
}
/* Featured Image */
#featured-image {
  margin: 2rem auto 2.5rem;
  display: block;
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
}

#featured-image img {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}