
:root {
  --nav-height: 125px;
  --footer-height: 30px;
  --footer-padding: 4px;
  --toc-width: 220px;
  --thumb-width: 160px;

  --border: #e5e7eb;
  --link: #2563eb;
  --text: #333333;
  --muted: #575b63;
  --bg-light: #fafafa;
}

html {
  scroll-behavior: smooth;
}

/* Reset */
* { box-sizing: border-box; }
body {
  margin: 0;
  font-family: Arial, Helvetica, sans-serif;
  color: var(--text);
  line-height: 1.6; /* space between text lines */
}

.subTitle{
    font-size: 75%;
}

/* ---------- Top Navigation ---------- */
.top-nav {
  position: sticky;
  top: 0;
  height: var(--nav-height);
  font-size: 120%;
  line-height: 1.0; /* space between text lines */
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 5px 10px 5px 5px; /* top | right | bottom | left */
  z-index: 1000;
  background-color: rgba(21,67,96,0.99);
  border-radius: 3px;
}

.top-nav .myLogo {
    display: flex;
}

.myLogo {
    height: calc(var(--nav-height) - 10px);
    width: auto;
    border-radius: 3px;
    cursor: pointer;
  }

.top-nav ul {
    list-style: none;
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
}

.top-nav a {
    text-decoration: none;
    color: white;
}

.top-nav a:hover {
   border-radius: 3px;
   background-color: rgba(36,113,163,0.99);
   color: black;
}

/* ---------- Layout ---------- */
.page {
    display: grid;
    flex: 1;
    grid-template-columns: 0.7fr 3fr 0.5fr;
}

/* ---------- left - Table of Contents ---------- */
aside.toc {
  position: sticky;
  top: var(--nav-height);
  height: calc(100vh - var(--nav-height));
  padding: 1.25rem;
  background: var(--bg-light);
  border-right: 1px solid var(--border);
  overflow-y: auto;
}

.toc h3 {
  font-size: 90%;
}

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

.toc li {
  margin-bottom: 0.5rem;
}

.toc a {
  text-decoration: none;
  color: var(--link);
  font-size: 90%;
}

.toc a:hover{
  color: blue;
}

/* ---------- center - Main Content ---------- */
main {
  padding: 0.5rem 2rem;
  max-width: calc(vw - var(toc-width) - var(--thumb-width) );
}

section {
  margin-top: 2rem;
  scroll-margin-top: calc(var(--nav-height) + 1rem);
}

section h1 {
  font-size: 160%;
}

section h2 {
  font-size: 140%;
}

.myVideo{
    width:90%;
    display:block;
    margin:auto;
}

.myimg {
  max-width:90%;
  height:auto;
  display:block;
  margin:auto;
}

/* ---------- right - Thumbnails ---------- */
aside.thumbs {
  position: sticky;
  top: var(--nav-height);
  height: calc(100vh - var(--nav-height) - var(--footer-height));
  padding: 1.25rem;
  border-left: 1px solid var(--border);
  background: var(--bg-light);
}

.thumbs h3 {
  font-size: 90%;
}

.thumbs img {
  width: 100%;
  margin-bottom: 0.75rem;
  border-radius: 3px;
  cursor: pointer;
  z-index: 50;
}

.thumbs img:hover {
  border: 2px solid blue;
}

/* ---------- Footer ---------- */
 footer {
    background: rgba(21,67,96,0.99);
    border-radius: 3px;
    color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    font-size: 80%;
    z-index: 100;
    height: var(--footer-height);
}
footer img {
    width: auto;
    height: calc( var(--footer-height) - 2 * var(--footer-padding) );
    object-fit: cover;
    /*border-radius: 3px;*/
    filter: invert(100%);
    cursor: pointer;
    padding-top: calc(var(--footer-padding) + 1px);
    padding-bottom: clc(var(--footer-padding) - 1px);
    padding-left: 10px;
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .page {
    grid-template-columns: var(--toc-width) 1fr;
  }
  aside.thumbs {
    display: none;
  }
}

@media (max-width: 900px) {
  .page {
    grid-template-columns: 1fr;
  }
  aside.toc {
    display: none;
  }
}

@media (max-width: 650px) {
    main {
        max-width: 500px;
    }
    .top-nav {
        flex-wrap: wrap;
        justify-content: center;
    }
    .top-nav a {
        font-size: 70%;
    }
    .myLogo{
        height: 40px;
        width: auto;
    }
    .myVideo{
        width:100%
    }
}


#toTop {
  display: none; /* Hidden by default */
  position: fixed; /* Fixed/sticky position */
  bottom: 32px; /* Place the button at the bottom of the page */
  right: 20px; /* Place the button 30px from the right */
  z-index: 100; /* Make sure it is on top ov everything */
  border: none; /* Remove borders */
  outline: none; /* Remove outline */
  background-color: rgba(26,82,118,0.99);
  color: white; /* Text color */
  cursor: pointer; /* Add a mouse pointer on hover */
  padding: 10px; /* Some padding around text*/
  border-radius: 3px; /* Rounded corners */
  font-size: 80%; /* Increase font size */
}

#toTop:hover {
   background-color: rgba(36,113,163,0.99);
   color: black;
}

