nav {
  display: flex;
  flex-direction: row;
  /* Explicitly set row direction for nav */
  align-items: center;
  width: 100%;
  min-height: 56px;
  position: relative;
  border-bottom: 1px solid #444444;


  padding: 0.5rem;
  /* Added for some breathing room */
}

.navleft {
  flex-shrink: 0;
  /* Prevents navleft from shrinking */
  font-size: 1.2rem;
  margin: 0;
  padding: 0;
  padding-left: 10px;

  white-space: nowrap;
  /* Prevents navleft text from wrapping */
}

.spacer {
  flex-grow: 1;
  /* Allows the spacer to take up available space */
}

/* Prevent overlap by setting a minimum left boundary */
.menu::before {
  content: '';
  display: block;
  width: 0;
  margin-left: calc(-50% + 500px);
  /* Adjust 200px based on navleft width */
  pointer-events: none;
  /* Ensures this doesn't interfere with clicks */
}

.menu {
  display: flex;
  justify-content: center;
  /* Centers the menu items horizontally */
  gap: 1rem;
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  /* Offsets by half its width */
  min-width: 0;
  /* Allows menu to shrink if needed */
  flex-wrap: nowrap;
  /* Keeps items in a single row by default */

}

nav .menu a {
  text-decoration: none;
  color: black;
  white-space: nowrap;
}

.menu a:hover {
  text-decoration: underline;
}

.hamburger {
  display: none;
  /* Hidden on desktop */
  background: none;
  border: none;
  font-size: 1.5rem;
  color: black;
  cursor: pointer;
  padding: 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
  nav {
    flex-direction: row;
    padding: 0.5rem;
    position: relative;
    /* Remove relative positioning on mobile */
    height: auto;
    /* Allow nav to expand with content */
    justify-content: space-between;
    /* Align navleft and hamburger */
  }

  .navleft {
    /*margin-bottom: 0.5rem;*/
    margin-bottom: 0;
  }

  .hamburger {
    display: flex;
    /* Show hamburger on mobile */
  }

  .spacer {
    display: none;
  }

  .menu {
    display: none;
    /* Hidden by default on mobile */
    position: absolute;
    top: 100%;
    /* Below nav */
    right: 0;
    left: auto;
    transform: none;
    width: auto;
    flex-direction: column;
    align-items: center;
    background-color: #eeeeeeb0;
    /* Match nav background */
    padding: 1rem;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.8);
    /* Optional shadow */
    z-index: 1;
    transition: all 0.3s ease;
  }

  @media (prefers-color-scheme:dark) {
    .menu {
      background-color: #222222b0;
    }

    .hamburger {
      color: #8bc2e7;
    }
  }

  .menu.active {
    display: flex;
    /* Show when toggled */
  }

  .menu::before {
    display: none;
    /* No need for this in vertical mode */
  }

  .menu a {
    padding: 0.5rem;
    width: 100%;
    text-align: center;
  }


  /* Remove the dots between links in vertical mode */
  .menu>span {
    display: none;
  }
}

/* Ensure content below nav isn't overlapped */
body>*:not(nav) {
  margin-top: 1rem;
  /* Adds space after nav for other content */
}

ol {
  list-style-position: outside;
  padding-left: 1em;
}

ul {
  margin: 0;
  padding: 0;
  padding-left: 1em;
}


dt {
  font-weight: bold;
}

li {
  margin-bottom: calc(1.75rem / 2);
}

code .bold {
  font-weight: bold;
}

.twitter-tweet {
  align-self: center;
}

h1,
h2,
h3,
h4,
h5 {
  text-rendering: optimizeLegibility;
  margin-bottom: 0;
}

h1 {
  font-family: 'Montserrat', sans-serif;
  font-weight: 900;
  font-size: 2.5rem;
  line-height: 1.1;
}

h2 {
  font-size: 1.73286rem;
}

h4 {
  text-transform: uppercase;
  letter-spacing: 0.140625em;
}

hr {
  width: 100%;
}

body {
  display: flex;
  flex-direction: column;
  align-items: center;
  word-wrap: break-word;
}

html {
  font: 100%/1.75 'Merriweather', 'Georgia', serif;
  box-sizing: border-box;
  overflow-y: scroll;
}

#content {
  /*max-width: 42rem;*/
  max-width: 60rem;
  width: 100vw;
  /*padding: 2.625rem 1.3125rem;*/
  padding: 1rem 1.3125rem;
}

div.highlight {
  border-radius: 6px;
}

pre>code {
  border: none;
  padding: 15px;
  font-family: monospace, monospace;
  font-size: 0.8em;
  line-height: 1.3em !important;
  display: inline-block;
  box-sizing: border-box;
  min-width: 100%;
}

pre {
  color: white;
  border-radius: 6px;
  margin: 0;
  padding: 0;
  background-color: #1E1E1E !important;
  font-size: 0.85em;
  overflow: auto;
}

code {
  border-radius: 4px;
  /*border: 1px solid #d3d3d3;*/
  padding: 3px;
  /*font-size: 1.1em;*/
  background-color: #1E1E1E !important;
}

navleft,
h1,
h2,
h3,
h4,
p,
ul,
li {
  code {
    background-color: #6e6e6e00 !important;
    /*color: white;*/
  }
}

blockquote {
  margin-left: -1.75rem;
  margin-right: 1.75rem;
  margin-top: 0;
  padding-bottom: 0;
  padding-left: 1.42188rem;
  padding-right: 0;
  padding-top: 0;
  margin-bottom: 1.75rem;
  font-size: 1.20112rem;
  line-height: 1.75rem;
  color: hsla(0, 0%, 0%, 0.79);
  font-style: italic;
  border-left: 0.32813rem solid hsla(0, 0%, 0%, 0.9);
}

blockquote p {
  margin: 0;
  margin-bottom: 15px;
}


.warning h1 {
  color: white;
  border-color: #0292ca !important;
  background-color: #0292ca !important;
}

.info h1 {
  color: white;
  border-color: orange !important;
  background-color: orange !important;
}


.toc a {
  color: #606060;
}


.noupper {
  font-family: 'Merriweather', serif;
  font-family: -apple-system, BlinkMacSystemFont, "Roboto", "Segoe UI", "Helvetica Neue", "Lucida Grande", Arial, sans-serif;
  font-style: normal;
  font-weight: bold;

  span,
  a {
    text-decoration: none;
    color: black;
    white-space: nowrap;
  }

  a:hover {
    text-decoration: underline;
  }
}

@media (prefers-color-scheme:dark) {
  pre {
    color: white;
  }

  code {
    color: white;
  }

  nav {
    background-color: #101010;
  }

  body {
    background: #111;
    color: #bbb;
  }

  h1,
  h2,
  h3,
  h4,
  h5,
  h6,
  strong {
    color: #e8e8e8
  }

  hr {
    border-top: 1px solid #797979
  }

  a {
    color: #8bc2e7
  }

  blockquote {
    border-color: #fff;
    color: inherit
  }

  .time {
    color: #8bc2e7 !important
  }




  pre,
  code {
    font-size: 12pt;
    direction: ltr;
  }

  pre>code {
    overflow: auto;
    padding: 0.5em;
    background: #f8f8f8;
    color: black;
    line-height: normal;
  }


  .code {
    font-family: monospace;
    font-size: 0.8em;
  }


  .warning h1 {
    color: white;
    border-color: #0292ca !important;
    background-color: #0292ca !important;
  }

  .info h1 {
    color: white;
    border-color: orange !important;
    background-color: orange !important;
  }

  .toc a {
    color: #bbb
  }

  .noupper {
    font-family: 'Merriweather', serif;
    font-family: -apple-system, BlinkMacSystemFont, "Roboto", "Segoe UI", "Helvetica Neue", "Lucida Grande", Arial, sans-serif;
    font-style: normal;
    font-weight: bold;

    span,
    a {
      color: white;
      text-decoration: none;
    }

    a:hover {
      text-decoration: underline;
    }
  }

  nav .menu a {
    text-decoration: none;
    color: #8bc2e7;
    white-space: nowrap;
  }

  /* Hover effect for mobile (if supported) */
  .menu a:hover {
    /* Brighter blue */
    color: #a8d5f0;
    text-decoration: underline;

  }
}


.highlight {
  background-color: #1E1E1E;
  color: #D4D4D4;
}

p:empty {
  margin: 0;
}

* {
  box-sizing: inherit;
}

*:before {
  box-sizing: inherit;
}

*:after {
  box-sizing: inherit;
}

.post-link {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-weight: 800;
  font-size: 1.3rem;
  line-height: 1.5rem;
}

.post-byline {
  font-size: 0.83255rem;
  line-height: 1.75rem;
  display: block;
  margin-bottom: 1.75rem;
  margin-top: 0;
}

#post-body p:nth-of-type(1) {
  margin-top: 0;
}

#post-body {
  margin-top: 1.75rem;
  display: flex;
  flex-direction: column;
}

#post-description {
  margin-top: 1.75rem;
  text-align: right;
  font-style: italic;
  font-weight: 100;
}

h1:nth-of-type(1) {
  margin-bottom: 0;
}

img {
  max-width: 100%;
}


figure img {
  display: block;
  max-width: 100%;
  width: 100vw;
  margin-left: auto;
  margin-right: auto;
  padding: 0;
  margin-bottom: 10px;

}

figure {
  margin: 0;
  padding: 0;
  margin-bottom: 1.75rem;
}

figcaption {
  text-align: center;
  font-size: 0.9em;
}

iframe {
  align-self: center;
}

.video-container {
  position: relative;
  padding-bottom: 56.25%;
  padding-top: 30px;
  height: 0;
  overflow: hidden;
}

.video-container iframe,
.video-container object,
.video-container embed {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
}



.block {
  border: 1px dashed #CCC;
}

.block.padded {
  margin: 10px;
  border: 1px solid #CCC;
}

.block p {
  padding-top: 0;
  font-size: 0.9em;
  padding-left: 15px;
  padding-right: 15px;
}

.block h1 {
  font-size: 1.17em;
  position: relative !important;
  margin: 0 !important;
  text-align: left;
  padding-left: 15px;
  padding-right: 15px;
  padding-top: 2px !important;
  border: 1px solid #CCC;
  color: #111;
  background-color: #CCC;
}


.block.info {
  margin-bottom: 1.5rem;
}

.warning {
  border-color: #0292ca !important;
}

.warning ul {
  margin-top: 0;
  padding-top: 1em;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  line-height: 1.5;
  padding-left: 2rem;
}


.warning p {
  padding-top: 1rem;
  /*color: blue;*/
}

.info {
  border-color: orange !important;
}

.info ul {
  margin-top: 0;
  padding-top: 1em;
  padding-left: 1.5rem;
  padding-right: 1.5rem;
  line-height: 1.5;
  padding-left: 2rem;
}

.info p {
  padding-top: 1rem;
  /*color: blue;*/
}

.nopara p {
  padding: 0;
  margin: 0px;
  margin-bottom: -5px;
}




#header {
  font-size: 1.7rem;
  margin: 0;
  padding: 0;
}

.reset-a,
.reset-a:hover,
.reset-a:visited,
.reset-a:focus,
.reset-a:active {
  text-decoration: none;
  color: inherit;
  outline: 0;
}

#prev-next {
  display: flex;
  flex-direction: column;
  align-items: center;
}

@media screen and (min-width:500px) {
  p {
    text-align: justify;
  }
}




pre>code {
  background: #1e1e1e;
  color: #f8f8f2;
  line-height: normal;
}


figcaption {
  font-style: italic;
}


p>img:only-child {
  display: block;
  margin: auto;
}

video {
  max-width: 100%;
}

.menu a {
  padding-left: 1rem;
  padding-right: 1rem;
}

.menu-small a {
  padding-left: 0.5rem;
  padding-right: 0.5rem;
}









.navbar-logo {
    display: flex;
  height: 3rem;
  min-width: 3rem;
  padding: 0;
  margin: 0;

}
