:root { 
    --color-ceramic: #fcfcfc;
    --color-obsidian: hsl(0, 5%, 7%);
    --color-hermes: hsl(24, 91%, 51%);
  
    --color-background: var(--color-ceramic);
    --color-text: var(--color-obsidian);
    --color-accent: var(--color-hermes);
    --color-accent-rgb: 255, 136, 0;
  }
  
  @media (prefers-color-scheme: dark) {
    :root {
      --color-background: var(--color-obsidian);
      --color-text: var(--color-ceramic);
      --color-accent: hsl(24, 91%, 66%);
      --color-accent-rgb: 255, 153, 51;
    }
  }
  
  html {
    margin: 0;
    padding: 0;
    scroll-behavior: smooth;
    scroll-padding-top: 20px;
  }
  
  body {
    margin: 0;
    padding: 0;
  }
  
  body {
    background-color: var(--color-background);
    color: var(--color-text);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    font-family: system-ui, -apple-system, sans-serif;
    padding: 24px 16px;
    box-sizing: border-box;
    min-height: 100vh;
  }
  
  .page-wrapper {
    width: 100%;
    max-width: 500px; /* Reduced by 25% from 800px */
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px; /* Reduced from 30px */
  }
  
  .header {
    text-align: left;
    margin-bottom: 0;
    padding-bottom: 6px; /* Reduced from 30px */
    align-self: flex-start;
  }
  
  .tagline {
    color: var(--color-text);
    text-align: left;
    font-size: clamp(18px, 5vw, 24px);
    font-weight: 600;
    line-height: 1.3;
    margin-bottom: 6px;
  }
  
  .content-container {
    width: 100%;
    max-width: 500px; /* Reduced by 25% from 800px */
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 2px; /* Reduced from 20px */
  }
  
  /* Page content styles */
  .page-section {
    margin-bottom: 6px; /* Reduced from 30px */
    width: 100%;
  }
  
  .page-section h2, summary {
    font-size: clamp(16px, 4vw, 20px);
    font-weight: 600;
    margin-bottom: 6px; /* Reduced from 16px */
    color: var(--color-text);
  }
  
  .page-section p {
    font-size: clamp(14px, 3vw, 16px);
    line-height: 1.5;
    margin-bottom: 6px; /* Reduced from 16px */
  }
  
  .page-section a {
    color: var(--color-accent);
    text-decoration: none;
  }
  
  .page-section a:hover {
    text-decoration: underline;
  }
  
  .page-section ul,
  .page-section ol {
    margin: 16px 0 16px 0; /* Reduced from 20px */
    padding-left: 20px;
  }

  .page-section h3 {
    font-size: clamp(15px, 3.5vw, 17px);
    font-weight: 600;
    margin: 20px 0 6px;
  }

  .page-section code {
    font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
    font-size: 0.9em;
  }

  .page-section pre {
    background: rgba(128, 128, 128, 0.1);
    border-radius: 6px;
    padding: 10px 12px;
    margin: 12px 0;
    overflow-x: auto;
    font-size: 13px;
    line-height: 1.45;
  }

  .page-section pre code {
    font-size: inherit;
  }

  .table-wrap {
    overflow-x: auto;
    margin: 12px 0;
  }

  .page-section table {
    border-collapse: collapse;
    font-size: 14px;
    line-height: 1.4;
  }

  .page-section th,
  .page-section td {
    text-align: left;
    vertical-align: top;
    padding: 6px 8px;
    border-bottom: 1px solid rgba(128, 128, 128, 0.25);
  }

  .page-section th {
    font-weight: 600;
  }

  /* Wikipedia-style table of contents, numbered 1, 5.1 etc. via counters */
  .toc {
    display: inline-block;
    border: 1px solid rgba(128, 128, 128, 0.3);
    background: rgba(128, 128, 128, 0.06);
    padding: 8px 14px;
    margin: 8px 0 12px;
  }

  .toc-title {
    font-weight: 600;
    font-size: 14px;
    text-align: center;
    margin-bottom: 4px;
  }

  .page-section .toc ol {
    list-style: none;
    counter-reset: toc;
    margin: 0;
    padding-left: 0;
  }

  .page-section .toc ol ol {
    padding-left: 1.4em;
    margin-top: 6px;
  }

  /* Same rhythm as body list items */
  .page-section .toc li {
    counter-increment: toc;
    margin: 0 0 6px;
    font-size: 14px;
    line-height: 1.5;
  }

  /* Wikipedia-style rule under main section headings (docs only) */
  .page-section.docs h2 {
    margin-top: 32px;
    padding-bottom: 4px;
    border-bottom: 1px solid rgba(128, 128, 128, 0.35);
  }

  .page-section .toc li::before {
    content: counters(toc, ".") " ";
    opacity: 0.6;
  }
  
  .page-section li {
    margin-bottom: 6px; /* Reduced from 8px */
    font-size: clamp(14px, 3vw, 16px);
    line-height: 1.5;
  }
  
  .footer {
    width: 100%;
    max-width: 500px; /* Reduced by 25% from 800px */
    text-align: center;
    font-size: 12px;
    margin-top: 16px;
  }
  
  .footer-links {
    display: flex;
    justify-content: center;
    gap: 16px;
    margin-bottom: 8px;
  }
  
  .footer-links a {
    color: var(--color-text);
    text-decoration: none;
    opacity: 0.6;
  }
  
  .footer-links a:hover {
    color: var(--color-accent);
    opacity: 1;
  }
  
  .footer-copyright {
    color: var(--color-text);
    opacity: 0.6;
    font-size: 12px;
  }
  
  @media (max-width: 767px) {
    .page-section h2 {
      font-size: 18px;
    }
    
    .page-section p,
    .page-section li {
      font-size: 15px;
    }
  }
  