body {
  font-family: 'Georgia', serif;
  font-size: 18px;
  line-height: 1.6;
  background: #EEE;
  color: #333;
  min-height: 100vh;
  display: grid;
  grid-template-rows: auto auto 1fr auto;
}

p {
  margin-bottom: 1em;
  margin-top: 1em;
}

a {
  color: #854dc1;
  word-break: break-all; /* Breaks long URLs when necessary */
}

a:hover {
  color: #4dacc1;
  text-decoration: underline;
}

canvas {
  margin-top: 2em;
  margin-bottom: 2em;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.container {
  max-width: 1050px;
  margin: 50px auto;
  background: #fff;
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.2);
}

.container main {
  padding: 50px 80px 50px 80px;
}

header, footer {
  text-align: center;
  background: #d7ecfb;
  color: #3d4168;
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: 80px;
}

header a, footer a {
  display: flex;
}

footer {
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.2);
}

h1, h2, h3 {
  font-family: serif;
  color: #3d4168;
}

h1 {
  font-size: 2em;
  font-weight: bold;
  margin-bottom: 20px;
}

h2 {
  font-size: 1.6em;
  margin-bottom: 15px;
}

h3 {
  font-size: 1em;
  margin-bottom: 10px;
}

ol, ul {
  list-style-position: outside;
  margin-left: 20px;
}

hr {
  border: 5px solid #d7ecfb;
  border-radius: 5px;
  margin-top: 40px;
  margin-bottom: 40px;
}

/* Navigation */
.navbar {
  height: 2.8em;
  font-family: serif;
  background: #ffffff;
  color: #3d4168;
  box-shadow: 0 0 8px 0 rgba(0, 0, 0, 0.2);
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 20px;
  z-index: 0;
}

.navbar a {
  color: #464646;
  text-decoration: none;
  font-size: 18px;
}

.navbar a:hover {
  text-decoration: underline;
  color: #4dacc1;
}

/* Responsive Design */
@media (max-width: 768px) {
  .container {
    width: 100%;
    padding: 10px;
  }

  .container main {
    padding: 10px;
  }

  .responsive-chart {
    width: 100%;
    min-height: 300px;
    height: 50vh
  }

  .navbar {
    font-size: 16px;
  }

  h1 {
    font-size: 2em;
  }

  h2 {
    font-size: 1.7em;
  }

  h3 {
    font-size: 1.4em;
  }
}

@media print {
  body {
    background: #fff !important;
    color: #000 !important;
    display: block !important;
  }

  .container {
    max-width: 100% !important;
    margin: 0 !important;
    box-shadow: none !important;
    padding-left: 40px;
    padding-right: 40px;
  }

  .container main {
    padding: 0 !important;
  }

  header, footer, .navbar {
    page-break-before: avoid;
    page-break-after: avoid;
    page-break-inside: avoid;
  }

  .navbar {
    height: auto !important;
    box-shadow: none !important;
    border-bottom: 1px solid #000 !important;
  }

  h1, h2, h3 {
    color: #000 !important;
  }

  a {
    color: #000 !important;
    text-decoration: underline !important;
    word-break: break-word !important;
  }

  footer {
    position: relative !important;
    bottom: 0 !important;
    width: 100% !important;
    box-shadow: none !important;
  }
}

