html {
  font-size: 65%; }

body {
    -webkit-animation-delay: 0.1s;
    -webkit-animation-name: fontfix;
    -webkit-animation-duration: 0.1s;
    -webkit-animation-iteration-count: 1;
    -webkit-animation-timing-function: linear;
    font-size: 1.6em; /* currently ems cause chrome bug misinterpreting rems on body element */
    line-height: 1.7;
    font-weight: 400;
    font-family: "Noto Sans", sans-serif;
    color: #222; 
}

@-webkit-keyframes fontfix {
    from { opacity: 1; }
    to   { opacity: 1; }
}

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  margin-bottom: 2rem;
  font-weight: 300; }
h1 { font-size: 4.0rem; line-height: 1.2;  letter-spacing: -.1rem;}
h2 { font-size: 3.6rem; line-height: 1.25; letter-spacing: -.1rem; }
h3 { font-size: 3.0rem; line-height: 1.3;  letter-spacing: -.1rem; }
h4 { font-size: 2.4rem; line-height: 1.35; letter-spacing: -.08rem; margin-top:2.4rem;}
h5 { font-size: 1.8rem; line-height: 1.5;  letter-spacing: -.05rem; }
h6 { font-size: 1.5rem; line-height: 1.6;  letter-spacing: 0; }

div#headpane {

    position:relative;
    margin-left:auto;
    margin-right:auto;
    margin-top:40px;
    height:auto;
    width: 950px;
}

div#contentpane {
    
    position:relative;
    margin-top: -10px;
    margin-left:auto;
    margin-right:auto;
    padding-bottom: 100px;
    color: #222222;
    font-size:100%;
    width: 85%; 
    background-color: #FFFFFF;
    clear: both;
    line-height: 150%;
    z-index: 1;
}

div#content {
    position: relative;
    top: 20px;
    margin-left:40px;
    margin-right:40px;
    width: auto;
}

div#pagetitle{
    
    text-align:left;
    margin-top: 3%;
    /*margin-left: 10%;*/
    margin-left: auto;
    margin-right: auto;
    width: 700px;
    margin-bottom: 3%; /*previously 4*/
    display: flex;
    justify-content: center;
}

div#justifyp {
    text-align: justify;
    text-justify: inter-word;
}

#headerimg {
    margin-left: 100px;
    border: 2px solid #FFFFFF;
    width: 180px;
    height: auto;
    margin-bottom: 10px;
    margin-right: 10px;
}

#headerimg img {
    width: 100%;
    height: auto;
    display: block;
}

#name {
    vertical-align: top;
    text-align: center;
}

p {
    height: auto;
    margin: 0;
    margin-bottom: 1em;
}

h1{
    color: #222222;     
    font-weight: bold;
    margin: 0% 0% 1% 0%;
}

h2{
    color: #222222;
    margin: -1% 0%;
    font-weight: bold;
}

h3 {
    font-weight: bold;
}

h1 > a{
    color: #222222;
    text-decoration: none;
    font-weight: bold;
}

h1>a:hover {
    color: #222222;
    text-decoration: none;
    font-weight: bold;
}

#footer {
    margin: 30px 0px;
    text-align: center;
    position: static;
    bottom: 0px;
    font-size:70%;
    width: 100%;
    color: #222222;
    z-index: 0;
    display: flex;
    justify-content: center;
    align-items: flex-start;    
}

#footer a:hover, #contentpane a:hover {
    /* color: #40A596; */
    filter: brightness(0.7) saturate(1.2) hue-rotate(10deg);
}

hr {
    color: #222222;
    height: 1px;
}

a {
    color: #98866b;  
    text-decoration: none;
    /*font-weight: normal;*/
}

table ol {
    margin: 0%;
    margin-left: -1.3em;
}

.rg {
    border-collapse: collapse;
    text-align:left;
    vertical-align: top;
}

.rg table, .rg th, .rg td{
    border-bottom: 1px solid black;
    border-collapse: collapse;
    vertical-align: top;
}

.rg th, .rg td {
    padding: 5px 10px;
}

.paper {
  margin-bottom: 20px 
}

.paper p {
  margin-bottom: 2px 
}
  
.divider {
    height: 2px;
    border: #222222;    
    background-color: #222222;  
    margin-top: 3.2rem;  
    margin-bottom: 2.4rem;  
  }
  
.nav {
    width: 100%;
    background-color: #98866b; 
    border-color: #d3f3ef;
    color: #222222;
    margin-top: -13px;
    margin-left: -8px;
    margin-bottom: 20px;
    text-align: center;
    font-size: 90%;
    position: fixed;
    z-index: 2;
    display: flex;
    justify-content: space-evenly;
    align-items: center;    
    height: 50px;
}

.nav div {
    padding: 0px 5px;
}

.nav a {
    color: #e9e9e9;
}

.nav a:hover {
    color: #222222;
}

#empty {
    width: 100%;
    height: 40px;
}

.on {
    font-weight: bold;
}

.on a {
    color: #ffffff;
}

#buffer {
    width: 100%;
    height: 140px;
    z-index: 0;
}

#logo {
    height: 15pt;
    margin-right: 2px;
    margin-left: 5px;
    padding-top: 2px;
}

.social-bar {
  justify-content: center;
  display: flex;
  gap: 26px;
  align-items: center;
}

.social-icon {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: #555;
  font-family: system-ui, sans-serif;
  font-size: 14px;
  transition: color 0.2s ease;
}

.social-icon svg {
  width: 22px;
  height: 22px;
  flex-shrink: 0;
}

/* Bluesky brand color override */
.social-icon.bluesky {
  color: #1185FE;
}

.social-icon.bluesky:hover {
  color: #1185FE;
}

/* hover effect */
.social-icon:hover {
  filter: brightness(0.9) saturate(1.2) hue-rotate(10deg);
}

/* Hide hamburger menu on desktop */
.nav-toggle {
  display: none;
}

.nav-label {
  display: none;
}

.mobile-header {
  display: none;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  html {
    height: 100%;
    font-size: 55%; /* Slightly smaller base font size for mobile */
  }

  body {
    font-size: 1.8em; /* Adjust body font size */
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }

  .mobile-header {
    height: 50px;
    background-color: #98866b;
    text-align: center;
    color: white;
    line-height: 50px;
    font-size: 1.8rem;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    position: sticky;
    top: 0;
    z-index: 100;
  }

  h1 { font-size: 3.6rem; }
  h2 { font-size: 3.2rem; }
  h3 { font-size: 2.8rem; }
  h4 { font-size: 2.4rem; }
  h5 { font-size: 1.8rem; }
  h6 { font-size: 1.6rem; }

  div#headpane {
    width: 95%; /* Make headpane responsive */
    margin-top: 20px;
  }

  div#contentpane {
    width: 95%; /* Increase width for mobile */
    padding-bottom: 50px;
    flex: 1; /* Make content area grow to fill available space */
  }

  div#content {
    margin-left: 20px;
    margin-right: 20px;
  }

  div#pagetitle {
    width: 90%; /* Make pagetitle responsive */
    margin: 0 auto 2% auto; /* Center horizontally */
    flex-direction: column; /* Stack elements vertically */
    text-align: center;
  }

  #headerimg {
    margin: 20px auto 30px auto; /* Center horizontally and add vertical spacing */
    width: 140px;
    height: auto;
    display: block; /* Ensure it's a block element for centering */
  }

  #headerimg img {
    width: 140px;
    height: auto;
  }

  #name {
    margin-top: 10px;
  }

  /* Hamburger menu styles */
  .nav-toggle {
    display: none; /* Hide the checkbox */
  }

  .nav-label {
    display: flex;
    position: absolute;
    top: 50%; /*10px;*/
    transform: translateY(-50%);
    left: 8px;
    z-index: 101;
    cursor: pointer;
    font-size: 2.5rem;
    line-height: 1;
    color: #ffffff;
    background-color: #98866b;
    padding: 0x 12px;
    border-radius: 5px;
  }

  .nav {
    position: fixed;
    top: 50px;
    left: -100%;
    width: 60%;
    max-width: 200px;
    height: auto;
    flex-direction: column;
    background-color: #98866b;
    margin: 0;
    padding: 10px 0;
    transition: left 0.3s ease;
    z-index: 2;
  }

  .nav div {
    padding: 10px 0;
    text-align: left;
    padding-left: 20px;
  }

  #nav-toggle:checked ~ .nav {
    left: 8px;
  }

  #empty {
    height: 20px;
  }

  #footer {
    position: static; /* Remove fixed positioning */
    margin: 20px 0;
    font-size: 60%;
    flex-shrink: 0; /* Prevent footer from shrinking */
  }

  #buffer {
    height: 80px;
  }

  .social-bar {
    gap: 20px;
  }

  .social-icon {
    font-size: 12px;
  }

  .social-icon svg {
    width: 20px;
    height: 20px;
  }
}

@media (max-width: 480px) {
  html {
    height: 100%;
    font-size: 50%; /* Even smaller for very small screens */
  }

  body {
    font-size: 1.8em;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
  }

  h1 { font-size: 3.5rem; }
  h2 { font-size: 3.2rem; }
  h3 { font-size: 2.8rem; }
  h4 { font-size: 2.4rem; }
  h5 { font-size: 2.0rem; }
  h6 { font-size: 1.6rem; }

  div#headpane {
    width: 98%;
  }

  div#contentpane {
    width: 98%;
    flex: 1; /* Make content area grow to fill available space */
  }

  div#pagetitle {
    width: 95%;
  }

  #headerimg {
    width: 120px;
    height: auto;
    margin: 15px auto 25px auto; /* Center and add spacing for smaller screens */
    display: block;
  }

  #headerimg img {
    width: 120px;
    height: auto;
  }

  .nav-label {
    font-size: 2.5rem;
    padding: 5px 10px;
  }

  .nav {
    width: 70%;
  }

  .social-bar {
    gap: 15px;
  }

  .social-icon {
    font-size: 11px;
  }

  .social-icon svg {
    width: 18px;
    height: 18px;
  }
}


