/* ========================================
   PhyEdu Class — Design System
   WikiDocs-style sidebar + content layout
   ======================================== */

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

/* --- Design Tokens --- */
:root {
  /* Colors — Deep Navy + Teal accent */
  --bg-primary: #0f1117;
  --bg-secondary: #161822;
  --bg-sidebar: #12141e;
  --bg-sidebar-hover: rgba(99, 179, 237, 0.08);
  --bg-sidebar-active: rgba(99, 179, 237, 0.14);
  --bg-card: #1a1d2e;
  --bg-card-hover: #1e2236;
  --bg-accent: rgba(99, 179, 237, 0.1);

  --text-primary: #e8eaf0;
  --text-secondary: #8b90a0;
  --text-muted: #5a5f73;
  --text-accent: #63b3ed;
  --text-sidebar-title: #a0aec0;
  --text-heading: #f0f2f8;

  --accent-primary: #63b3ed;
  --accent-secondary: #4fd1c5;
  --accent-gradient: linear-gradient(135deg, #63b3ed, #4fd1c5);
  --accent-glow: 0 0 20px rgba(99, 179, 237, 0.15);

  --border-color: rgba(255, 255, 255, 0.06);
  --border-sidebar: rgba(255, 255, 255, 0.04);

  --sidebar-width: 280px;
  --header-height: 60px;
  --content-max-width: 860px;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 32px rgba(0, 0, 0, 0.5);

  --transition-fast: 0.15s ease;
  --transition-normal: 0.25s ease;
  --transition-slow: 0.4s cubic-bezier(0.4, 0, 0.2, 1);
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html {
  font-size: 16px;
  scroll-behavior: smooth;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  font-family: 'Inter', 'Noto Sans KR', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-primary);
  line-height: 1.7;
  overflow-x: hidden;
  min-height: 100vh;
}

/* --- Layout Shell --- */
.app-shell {
  display: flex;
  min-height: 100vh;
}

/* --- Sidebar --- */
.sidebar {
  width: var(--sidebar-width);
  min-height: 100vh;
  background: var(--bg-sidebar);
  border-right: 1px solid var(--border-sidebar);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0;
  left: 0;
  bottom: 0;
  z-index: 100;
  transition: transform var(--transition-slow);
  overflow: hidden;
}

.sidebar-header {
  padding: 20px 20px 16px;
  border-bottom: 1px solid var(--border-sidebar);
  flex-shrink: 0;
}

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--text-primary);
}

.sidebar-logo .logo-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius-md);
  background: var(--accent-gradient);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  box-shadow: var(--accent-glow);
  flex-shrink: 0;
}

.sidebar-logo .logo-text {
  display: flex;
  flex-direction: column;
}

.sidebar-logo .logo-title {
  font-size: 15px;
  font-weight: 700;
  letter-spacing: -0.3px;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.sidebar-logo .logo-subtitle {
  font-size: 11px;
  color: var(--text-muted);
  font-weight: 400;
  margin-top: 1px;
}

/* Search */
.sidebar-search {
  padding: 12px 16px;
  flex-shrink: 0;
}

.sidebar-search input {
  width: 100%;
  padding: 8px 12px 8px 34px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  font-size: 13px;
  font-family: inherit;
  outline: none;
  transition: all var(--transition-fast);
}

.sidebar-search input::placeholder {
  color: var(--text-muted);
}

.sidebar-search input:focus {
  border-color: var(--accent-primary);
  background: rgba(99, 179, 237, 0.06);
  box-shadow: 0 0 0 3px rgba(99, 179, 237, 0.08);
}

.sidebar-search-wrapper {
  position: relative;
}

.sidebar-search-wrapper::before {
  content: '🔍';
  position: absolute;
  left: 10px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 13px;
  pointer-events: none;
  opacity: 0.5;
}

/* Navigation */
.sidebar-nav {
  flex: 1;
  overflow-y: auto;
  padding: 8px 0;
  scrollbar-width: thin;
  scrollbar-color: rgba(255,255,255,0.08) transparent;
}

.sidebar-nav::-webkit-scrollbar {
  width: 4px;
}

.sidebar-nav::-webkit-scrollbar-track {
  background: transparent;
}

.sidebar-nav::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.1);
  border-radius: 2px;
}

.nav-section {
  margin-bottom: 4px;
}

.nav-section-title {
  padding: 10px 20px 6px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
  color: var(--text-sidebar-title);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: space-between;
  user-select: none;
  transition: color var(--transition-fast);
}

.nav-section-title:hover {
  color: var(--text-primary);
}

.nav-section-title .toggle-icon {
  font-size: 10px;
  transition: transform var(--transition-normal);
  opacity: 0.5;
}

.nav-section-title .toggle-icon.collapsed {
  transform: rotate(-90deg);
}

.nav-section-items {
  overflow: hidden;
  transition: max-height var(--transition-normal);
}

.nav-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 20px 8px 28px;
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 13.5px;
  font-weight: 400;
  cursor: pointer;
  transition: all var(--transition-fast);
  border-left: 3px solid transparent;
  position: relative;
}

.nav-item:hover {
  color: var(--text-primary);
  background: var(--bg-sidebar-hover);
}

.nav-item.active {
  color: var(--accent-primary);
  background: var(--bg-sidebar-active);
  border-left-color: var(--accent-primary);
  font-weight: 500;
}

.nav-item .item-icon {
  font-size: 14px;
  flex-shrink: 0;
  width: 20px;
  text-align: center;
}

.nav-item .item-title {
  flex: 1;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.nav-empty {
  padding: 8px 20px 8px 28px;
  color: var(--text-muted);
  font-size: 12px;
  font-style: italic;
}

/* Sidebar Footer */
.sidebar-footer {
  padding: 12px 16px;
  border-top: 1px solid var(--border-sidebar);
  flex-shrink: 0;
}

.sidebar-footer-text {
  font-size: 11px;
  color: var(--text-muted);
  text-align: center;
}

.sidebar-footer-text a {
  color: var(--accent-primary);
  text-decoration: none;
}

/* --- Main Content Area --- */
.main-wrapper {
  flex: 1;
  margin-left: var(--sidebar-width);
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Header */
.main-header {
  height: var(--header-height);
  background: rgba(15, 17, 23, 0.85);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  display: flex;
  align-items: center;
  padding: 0 24px;
  position: sticky;
  top: 0;
  z-index: 50;
  gap: 16px;
}

.mobile-menu-btn {
  display: none;
  background: none;
  border: none;
  color: var(--text-secondary);
  font-size: 22px;
  cursor: pointer;
  padding: 4px;
  border-radius: var(--radius-sm);
  transition: all var(--transition-fast);
}

.mobile-menu-btn:hover {
  color: var(--text-primary);
  background: rgba(255,255,255,0.06);
}

.breadcrumb {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-secondary);
  flex: 1;
}

.breadcrumb-separator {
  color: var(--text-muted);
  font-size: 11px;
}

.breadcrumb-current {
  color: var(--text-primary);
  font-weight: 500;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.header-btn {
  background: none;
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  padding: 6px 12px;
  border-radius: var(--radius-sm);
  font-size: 12px;
  cursor: pointer;
  transition: all var(--transition-fast);
  font-family: inherit;
}

.header-btn:hover {
  color: var(--text-primary);
  border-color: var(--accent-primary);
  background: rgba(99, 179, 237, 0.06);
}

/* Content Area */
.main-content {
  flex: 1;
  padding: 32px 40px;
  max-width: calc(var(--content-max-width) + 80px);
}

/* --- Content Styles --- */
.material-content {
  animation: fadeInUp 0.35s ease;
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(12px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.material-content h1 {
  font-size: 2rem;
  font-weight: 700;
  color: var(--text-heading);
  margin-bottom: 12px;
  letter-spacing: -0.5px;
  line-height: 1.3;
}

.material-content h2 {
  font-size: 1.5rem;
  font-weight: 600;
  color: var(--text-heading);
  margin: 32px 0 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border-color);
}

.material-content h3 {
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--text-heading);
  margin: 24px 0 8px;
}

.material-content p {
  margin-bottom: 16px;
  color: var(--text-primary);
  line-height: 1.8;
}

.material-content .lead {
  font-size: 1.1rem;
  color: var(--text-secondary);
  margin-bottom: 24px;
  line-height: 1.8;
}

.material-content ul, .material-content ol {
  margin-bottom: 16px;
  padding-left: 24px;
}

.material-content li {
  margin-bottom: 6px;
  color: var(--text-primary);
}

.material-content a {
  color: var(--accent-primary);
  text-decoration: none;
  border-bottom: 1px solid transparent;
  transition: border-color var(--transition-fast);
}

.material-content a:hover {
  border-bottom-color: var(--accent-primary);
}

.material-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 16px 0;
  font-size: 14px;
}

.material-content thead th {
  background: rgba(99, 179, 237, 0.1);
  color: var(--text-accent);
  font-weight: 600;
  text-align: left;
  padding: 10px 14px;
  border-bottom: 2px solid rgba(99, 179, 237, 0.2);
}

.material-content tbody td {
  padding: 10px 14px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
}

.material-content tbody tr:hover {
  background: rgba(255, 255, 255, 0.02);
}

.material-content code {
  background: rgba(99, 179, 237, 0.1);
  color: var(--accent-secondary);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.9em;
  font-family: 'Consolas', 'Fira Code', monospace;
}

.material-content pre {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 16px 20px;
  overflow-x: auto;
  margin: 16px 0;
}

.material-content pre code {
  background: none;
  padding: 0;
  color: var(--text-primary);
}

.material-content img {
  max-width: 100%;
  border-radius: var(--radius-md);
  margin: 16px 0;
  box-shadow: var(--shadow-md);
}

/* Info Cards */
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 20px 24px;
  margin: 20px 0;
  transition: all var(--transition-normal);
}

.info-card:hover {
  background: var(--bg-card-hover);
  border-color: rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow-sm);
}

.info-card.accent {
  border-left: 3px solid var(--accent-primary);
  background: var(--bg-accent);
}

.info-card h3 {
  font-size: 1rem;
  margin-bottom: 10px;
  color: var(--text-heading);
}

.info-card p {
  margin-bottom: 0;
}

/* --- Sidebar extras --- */
.nav-divider {
  height: 1px;
  background: var(--border-sidebar);
  margin: 6px 16px;
}

.nav-home {
  padding: 10px 20px;
}

.nav-item .item-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  border-radius: 5px;
  background: rgba(99, 179, 237, 0.12);
  color: var(--accent-primary);
  font-size: 11px;
  font-weight: 600;
  flex-shrink: 0;
}

.nav-item.active .item-number {
  background: var(--accent-primary);
  color: #0f1117;
}

/* --- Book Cover / TOC --- */
.book-cover {
  animation: fadeInUp 0.4s ease;
}

.book-cover-header {
  text-align: center;
  padding: 48px 20px 36px;
  border-bottom: 1px solid var(--border-color);
  margin-bottom: 36px;
}

.book-badge {
  display: inline-block;
  padding: 6px 16px;
  background: rgba(99, 179, 237, 0.1);
  border: 1px solid rgba(99, 179, 237, 0.2);
  border-radius: 20px;
  font-size: 12px;
  font-weight: 500;
  color: var(--accent-primary);
  margin-bottom: 20px;
  letter-spacing: 0.5px;
}

.book-title {
  font-size: 2.8rem;
  font-weight: 700;
  background: var(--accent-gradient);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 10px;
  letter-spacing: -1px;
  line-height: 1.2;
}

.book-subtitle {
  font-size: 1.3rem;
  color: var(--text-secondary);
  font-weight: 400;
  margin-bottom: 16px;
}

.book-description {
  font-size: 0.95rem;
  color: var(--text-muted);
  max-width: 560px;
  margin: 0 auto 20px;
  line-height: 1.7;
}

.book-meta {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
}

.book-meta-item {
  font-size: 13px;
  color: var(--text-secondary);
}

/* Table of Contents */
.book-toc {
  max-width: 680px;
  margin: 0 auto;
}

.book-toc-heading {
  font-size: 1.3rem;
  font-weight: 600;
  color: var(--text-heading);
  margin-bottom: 20px;
  padding-bottom: 10px;
  border-bottom: 2px solid rgba(99, 179, 237, 0.2);
}

.toc-section {
  margin-bottom: 24px;
}

.toc-section-title {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-sidebar-title);
  margin-bottom: 8px;
  padding-left: 4px;
}

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

.toc-item {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 16px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  margin-bottom: 6px;
  cursor: pointer;
  transition: all var(--transition-normal);
}

.toc-item:hover {
  background: var(--bg-card-hover);
  border-color: rgba(99, 179, 237, 0.25);
  transform: translateX(4px);
  box-shadow: var(--shadow-sm);
}

.toc-number {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: var(--accent-gradient);
  color: #0f1117;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.toc-title {
  flex: 1;
  font-size: 14.5px;
  font-weight: 500;
  color: var(--text-primary);
}

.toc-arrow {
  color: var(--text-muted);
  font-size: 14px;
  transition: transform var(--transition-fast);
}

.toc-item:hover .toc-arrow {
  transform: translateX(3px);
  color: var(--accent-primary);
}

.toc-empty {
  padding: 10px 16px;
  color: var(--text-muted);
  font-size: 13px;
  font-style: italic;
}

/* Start Reading Button */
.book-start {
  text-align: center;
  padding: 32px 0 16px;
}

.btn-start {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 14px 32px;
  background: var(--accent-gradient);
  color: #0f1117;
  border: none;
  border-radius: var(--radius-md);
  font-size: 15px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  transition: all var(--transition-normal);
  box-shadow: var(--accent-glow);
}

.btn-start:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(99, 179, 237, 0.3);
}

.btn-start .btn-arrow {
  transition: transform var(--transition-fast);
}

.btn-start:hover .btn-arrow {
  transform: translateX(4px);
}

/* Page Number Badge */
.page-number-badge {
  display: inline-block;
  padding: 4px 12px;
  background: rgba(99, 179, 237, 0.1);
  border: 1px solid rgba(99, 179, 237, 0.15);
  border-radius: 6px;
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-primary);
  margin-bottom: 16px;
  letter-spacing: 0.3px;
}

/* Prev / Next Page Navigation */
.page-nav {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--border-color);
}

.page-nav-btn {
  display: flex;
  flex-direction: column;
  padding: 16px 20px;
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  cursor: pointer;
  transition: all var(--transition-normal);
  text-decoration: none;
}

.page-nav-btn:hover {
  background: var(--bg-card-hover);
  border-color: rgba(99, 179, 237, 0.25);
  box-shadow: var(--shadow-sm);
}

.page-nav-btn.next {
  text-align: right;
}

.page-nav-label {
  font-size: 11px;
  font-weight: 600;
  color: var(--accent-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 4px;
}

.page-nav-title {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
}

/* Loading Skeleton */
.content-loading {
  padding: 32px 0;
}

.skeleton {
  background: linear-gradient(90deg, var(--bg-card) 25%, var(--bg-card-hover) 50%, var(--bg-card) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--radius-sm);
}

.skeleton-title {
  width: 60%;
  height: 36px;
  margin-bottom: 16px;
}

.skeleton-text {
  width: 100%;
  height: 16px;
  margin-bottom: 10px;
}

.skeleton-text:nth-child(3) { width: 85%; }
.skeleton-text:nth-child(4) { width: 92%; }

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

/* Sidebar overlay for mobile */
.sidebar-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.6);
  z-index: 90;
  backdrop-filter: blur(4px);
}

/* --- Responsive --- */
@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }

  .sidebar.open {
    transform: translateX(0);
  }

  .sidebar-overlay.active {
    display: block;
  }

  .main-wrapper {
    margin-left: 0;
  }

  .mobile-menu-btn {
    display: block;
  }

  .main-content {
    padding: 20px 16px;
  }

  .material-content h1 {
    font-size: 1.6rem;
  }

  .book-title {
    font-size: 2rem;
  }

  .book-subtitle {
    font-size: 1.1rem;
  }

  .page-nav {
    grid-template-columns: 1fr;
  }

  .toc-item {
    padding: 10px 12px;
  }
}

@media (max-width: 480px) {
  .book-meta {
    flex-direction: column;
    gap: 8px;
  }
}

/* Print styles */
@media print {
  .sidebar, .main-header, .sidebar-overlay, .page-nav { display: none !important; }
  .main-wrapper { margin-left: 0 !important; }
  .material-content { max-width: 100%; }
}

/* ========================================
   Content Components
   ======================================== */

/* Lead text */
.material-content .lead {
  font-size: 1.1rem;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2rem;
  border-left: 3px solid var(--accent-primary);
  padding-left: 16px;
}

/* Info cards */
.info-card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 20px 24px;
  margin: 1.5rem 0;
}

.info-card.accent {
  border-left: 3px solid var(--accent-primary);
  background: linear-gradient(135deg, rgba(99,179,237,0.06), rgba(79,209,197,0.04));
}

.info-card h3 {
  margin-top: 0;
  font-size: 1.05rem;
  color: var(--text-accent);
}

.info-card p:last-child,
.info-card ul:last-child,
.info-card table:last-child {
  margin-bottom: 0;
}

/* Blockquotes */
.material-content blockquote {
  border-left: 3px solid var(--accent-secondary);
  background: rgba(79, 209, 197, 0.06);
  padding: 14px 20px;
  margin: 1.2rem 0;
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-primary);
  font-style: italic;
}

.material-content blockquote p {
  margin: 0;
}

/* Code blocks */
.material-content pre {
  background: #0d0f18;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  padding: 18px 20px;
  margin: 1.2rem 0;
  overflow-x: auto;
  font-size: 0.88rem;
  line-height: 1.65;
}

.material-content pre code {
  font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  color: #c9d1d9;
  background: none;
  padding: 0;
  border: none;
  font-size: inherit;
}

.material-content code {
  font-family: 'JetBrains Mono', 'Fira Code', 'Consolas', monospace;
  background: rgba(99, 179, 237, 0.1);
  color: var(--text-accent);
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.88em;
}

/* Tables - enhanced */
.material-content table {
  width: 100%;
  border-collapse: collapse;
  margin: 1.2rem 0;
  font-size: 0.92rem;
  background: var(--bg-card);
  border-radius: var(--radius-md);
  overflow: hidden;
  border: 1px solid var(--border-color);
}

.material-content thead th {
  background: rgba(99, 179, 237, 0.1);
  color: var(--text-accent);
  font-weight: 600;
  padding: 12px 16px;
  text-align: left;
  border-bottom: 2px solid var(--border-color);
}

.material-content tbody td {
  padding: 10px 16px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
  vertical-align: top;
}

.material-content tbody tr:last-child td {
  border-bottom: none;
}

.material-content tbody tr:hover {
  background: rgba(99, 179, 237, 0.04);
}

/* KaTeX math display */
.material-content .katex-display {
  margin: 1.2rem 0;
  padding: 12px 16px;
  background: rgba(15, 17, 23, 0.5);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  overflow-x: auto;
}

.material-content .katex {
  font-size: 1.1em;
  color: var(--text-primary);
}

/* Ordered & unordered lists */
.material-content ol,
.material-content ul {
  padding-left: 24px;
  margin: 0.8rem 0;
}

.material-content li {
  margin-bottom: 6px;
  line-height: 1.7;
}

.material-content li .katex {
  font-size: 1em;
}

/* Strong / emphasis */
.material-content strong {
  color: var(--text-heading);
}

/* Headings spacing */
.material-content h2 {
  margin-top: 2.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border-color);
}

.material-content h2:first-of-type {
  border-top: none;
  padding-top: 0;
}

.material-content h3 {
  margin-top: 1.8rem;
  color: var(--text-accent);
}
