html {
  font-size: 14px;
}

@media (min-width: 768px) {
  html {
    font-size: 16px;
  }
}



.btn:focus, .btn:active:focus, .btn-link.nav-link:focus, .form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.1rem white, 0 0 0 0.25rem #258cfb;
}

html {
  position: relative;
  min-height: 100%;
}
#conwayGoL {
  position: fixed;
  top: 0; left: 0;
  width: 100vw;
  height: 100vh;
  z-index: 0;
  display: block
}

@font-face {
  font-family: 'Textur';
  src: url('/fonts/textur.TTF') format('truetype');
}

.fraktur {
  font-family: 'UnifrakturMaguntia', cursive, serif;
}

.times {
  font-family: "Times New Roman", Times, serif;
}

.textur {
  font-family: 'Textur', serif;
}

.textur h1 {
  font-size: 7.5rem;
  display: inline-block;
  padding: 0em 0.5em;
  border: 2px solid #00ff99;
  box-shadow: 0 0 10px #00ff99;
  border-radius: 6px;
  margin-bottom: 0.5em;
  background-color: rgba(0,0,0,.7);
  /*-webkit-text-stroke: 1px rgba(0, 191, 255, 0.5);*/
}

.textur h2 {
  font-size: 1.75rem;
  color: #00ffea;
}

.textur h2.titlePage {
  position: relative;
  display: inline-block;
  
  padding: 0.1em 0.1em;
  border: 2px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 4px;
  background-color: rgba(0,0,0,.7);
}



body {
  margin-bottom: 60px;
  background-color: rgba(0, 0, 0, 1);
}

.form-floating > .form-control-plaintext::placeholder, .form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder, .form-floating > .form-control:focus::placeholder {
  text-align: start;
}

.royal-blue {
  color: #4169E1;
}

.dodger-blue {
  color: #1E90FF;
}

.sky-blue {
  color: #3399FF;
}

.turqoise-blue {
  color: #00BFFF
}

.fun-orange {
  color: #da800b !important;
}

.links {
  margin-top: 50px;
  text-align: center;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top:1rem;
  align-items: start;
}

.blog-accordion {
  display:block;
  gap: 1rem;
  margin-top:1rem;
  align-items:start;
  overflow-y: auto;
}

.accordion .blog-accordion {
  border: 2px solid #00ffbf;
  box-shadow: 0 0 10px #00ffbf;
}

.blog-accordion .accordion-body {
  color: #FFFFFF;
  background-color: RGBA(0,0,0,0.9);
  z-index:100;
  
}

.blog-accordion .accordion-header {
  color:#00ffbf;
}

.blog-accordion .accordion-header.active {
  background-color: RGBA(0,0,0,0.9);
}

.blog-accordion .accordion-header.active + .accordion-body {
  padding: 2rem;
  max-height: 500px;
  overflow-y: auto;
  pointer-events: auto;
}

.blog-accordion .accordion-header.active + .accordion-body::-webkit-scrollbar{
  width: 0.5rem;
}

.blog-accordion .accordion-header.active + .accordion-body::-webkit-scrollbar-track {
  background: RGBA(0,0,0,0);
}

.blog-accordion .accordion-header.active + .accordion-body::-webkit-scrollbar-thumb {
  background: #00FFBFAA;
  border-radius:3px;
}

.blog-accordion .accordion-header.active + .accordion-body::-webkit-scrollbar-thumb:hover {
  background: #00ffbf;
}

.blog-accordion .accordion-body em, .blog-accordion .accordion-body a {
  display: inline;
  white-space: normal;
  margin: 0;
  padding: 0;
}

.accordion-body table {
    border-collapse: collapse;
    width: 100%;
    margin: 1em 0;
}

.blog-accordion .accordion-body table th,
.accordion-body table td {
    border: 1px solid #ddd;
    padding: 8px 12px;
    text-align: left;
}




.accordion {
  position: relative;
  z-index: 20;
  width: 100%;
  border: 2px solid #ff0000;
  box-shadow: 0 0 10px #ff0000;
  margin: 10px 0;
  font-family:'Times New Roman', Times, serif;
}

.accordion-header {
  background-color: RGBA(0,0,0,0.7);
  color: rgb(255, 255, 255);
  font-weight: bold;
  font-size: 1.3rem;
  width: 100%;
  padding: 8px;
  border: none;
  text-align: center;
  cursor: pointer;
}

.accordion-header:hover {
  background: rgba(255,255,255,0.3);
}


.accordion-body {
  display: none;
  padding: 0;
  background: rgba(0,0,0,0.7);
  font-size: 1.1rem;
  max-height: 0;
  overflow: hidden;
  transition: 0.1s ease;
}

@keyframes gradientShift {
  0% {background-position: 0% 50%; }
  50% {background-position: 100% 50%; }
  100% {background-position: 0% 50%; }
}

.accordion-header.active + .accordion-body {
    display: block;
    max-height: 500px;
    padding: 0.5rem;
    animation: gradientShift 10s ease infinite;
}

.accordion-body a {
  display: block;
  margin: 0.5rem 1rem;
  color: rgb(255,255,255);
  text-decoration: underline;
  z-index: 19;
}

.accordion-body a:hover {
  color: #ff0000;
}

.header-bar {
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
  padding: 1rem;
}

.header-bar .page-title {
  font-family: 'Textur', serif;
  font-size: 5.5rem;
  color: #da800b;
  margin: 0;
  text-align: center;
  flex: 1;
  display: inline-block;
  padding: 0.1em 0.1em;
  border: 2px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 4px;
  background-color: rgba(0,0,0,.7);

}

.header-bar .home-link {
  position: absolute;
  left: 1rem;
  font-size: 1.2rem;
  text-decoration: underline;
  color: #00bfffb9;
}

.directory {
  font-size: 1rem;
  text-align: center;
}

.directory a {
  color: #ff9100;
  text-decoration: none;
  display: inline-block;
  padding: 0.25em 0.25em;
  border: 2px solid #ffffff;
  box-shadow: 0 0 10px #ffffff;
  border-radius: 4px;
  background-color: rgba(0,0,0,.7);
}

.directory a.textur {
  font-family: "Textur", serif;
}

.directory a:hover {
  background-color: rgba(255,255,255,0.3);
}

.big-title {
  font-size: 4rem;
}

.big-border {
  padding: 2em 2em;
  border: 2px solid #ac3030;
  box-shadow: 0 0 10px #ac3030;
  border-radius: 4px;
  background-color: rgba(0,0,0,.7);
}

.text-center, .textur, h1, h2, p {
  pointer-events: none;
}

.overlay {
  position: relative;
  pointer-events: none; /* pass clicks through */
  z-index: 1;
}

.overlay a, .overlay button, .overlay form, .overlay input{
  pointer-events: auto; /* keep interactive elements clickable */
}

@media (max-width: 768px) {
  .text-center h1 {
    font-size: 4rem;
  }
  .text-center h2 {
    font-size: 2rem;
  }
  .projects-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 480px) {
  .text-center h1 {
    font-size: 3rem;
  }
  .text-center h2 {
    font-size: 1rem;
  }
  .projects-grid {
    grid-template-columns: 1fr;
  }
}


.navbar {
  background: none;
  padding: 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
}

.nav-links {
  list-style: none;
  display: none;
  flex-direction: column;
  background-color: rgba(0,0,0,0.7);
  top: 100%;
  left: 0;
  padding: 1rem;
  margin: 0;
  font-family:'Times New Roman', Times, serif;
}

.nav-links.active {
  display: flex; /* show when active */
}

.nav-links li {
  margin: 0.5rem 0;
}

.nav-links a {
  color: #fff;
  text-decoration: none;
}

.nav-links a:hover {
  color: #ff0000;
  text-decoration: underline;
}

/* Burger button */
.nav-toggle {
  background-color: rgba(0,0,0,0.7);
  border: none;
  box-shadow: none;
  margin: 0;
  outline: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
  width: 40px;
  text-align: center;
  transition: width 0.5s ease;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 3px;
  background: #ff9100;
  transform-origin: left center;
  transition: width 0.5s ease, transform 0.3s ease;
}

/* Animate burger into X when active */
.nav-toggle:hover span:nth-child(1) {
  transform: translateY(4px);
}
.nav-toggle:hover span:nth-child(3) {
  transform: translateY(-4px);
}



.nav-toggle.active span:nth-child(1) {
  transform: translateY(8px);
}
.nav-toggle.active span:nth-child(2) {
  width: 100%;
  border-radius: 25px;
  transform-origin: left-center;
}
.nav-toggle.active span:nth-child(3) {
  transform:translateY(-8px);
}

.nav-wrapper {
  display: inline-block;
  border: 1px solid #ff0000;
  box-shadow: 0 0 10px #ff0000;
  border-radius: 2px;
  padding: 0;
  transition: all 0.3s ease;
  width: fit-content;
}

.nav-wrapper.active {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  background-color: rgb(0,0,0);
}

.nav-wrapper.active .nav-toggle {
  width: 100%;
  justify-content: center;
  border-right: none;
}

#automata-canvas {
  pointer-events: auto !important;
  position: relative;
  background-color: rgba(0,0,0,.7);
  border: 2px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 4px;
  padding: 0;
  cursor: auto;
  width: 100%;

  z-index: 20;

  text-align: center;
  flex: 1;
  display: inline-block;
  padding: 0.1em 0.1em;

}

.automata-output {
  background-color: rgba(0,0,0,.7);
  border: 1px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 2px;
  padding: 0;
  cursor: pointer;
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 1.1em;
  padding: 10px 20px;
  margin-right: 10px;
  color: #ffffff;
}


button {
  pointer-events: auto !important;
  background-color: rgba(0,0,0,.7);
  border: 1px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 2px;
  padding: 0;
  cursor: pointer;
  text-align: center;
  font-family: "Times New Roman", Times, serif;
  font-size: 16px;
  padding: 10px 20px;
  margin-right: 10px;
  color: #ffffff;
  z-index: 20;
}

button:hover {
  background-color: rgba(255,255,255,0.3);
}

button.active {
  background-color: rgba(0, 255, 234, 0.7);
  color: #000000;
}

.controls button {
  pointer-events: auto !important;
}

input {
  pointer-events: auto !important;
  z-index: 20;
  background-color: rgba(0,0,0,.7);
  border: 1px solid #00ffea;
  box-shadow: 0 0 10px #00ffea;
  border-radius: 2px;
  padding: 0;
  font-family: "Times New Roman", Times, serif;
  font-size: 1em;
  padding: 10px 20px;
  margin-right: 10px;
  color: #ffffff;
}
