html, body {
  height: auto;
  min-height: 100%;
}
body {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  font-family: 'Segoe UI', Arial, sans-serif;
  margin: 0;
  padding: 0;
  background: #f8f9fa;
  color: #222;
}
nav {
  background: #222;
  color: #fff;
  padding: 1em;
  text-align: center;
  box-shadow: 0 2px 8px rgba(0,0,0,0.08);
  position: relative;
}
nav .nav-links {
  display: inline;
}
nav .nav-logo {
  position: absolute;
  right: 1em;
  top: 50%;
  transform: translateY(-50%);
  height: 40px;
}
nav a {
  color: #fff;
  margin: 0 1em;
  text-decoration: none;
  font-weight: 500;
  letter-spacing: 0.5px;
  transition: color 0.2s;
}
nav a:hover {
  color: #00bcd4;
  text-decoration: underline;
}
main {
  max-width: 800px;
  margin: 2em auto;
  background: #fff;
  padding: 2em;
  border-radius: 10px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.07);
  flex: 1 0 auto;
  min-width: 40%;
}
h1, h2, h3 {
  font-weight: 600;
  color: #222;
  margin-top: 0;
}
ul {
  padding-left: 1.2em;
  margin: 1em 0;
}
li {
  margin-bottom: 0.5em;
}
p {
  line-height: 1.7;
  margin: 1em 0;
}
footer {
  text-align: center;
  padding: 2em 0;
  background: #222;
  color: #fff;
  font-size: 0.95em;
  margin-top: 2em;
  flex-shrink: 0;
}
@media (max-width: 600px) {
  main {
    padding: 1em;
    min-height: 200px;
  }
  nav {
    padding: 0.5em;
    position: static;
    text-align: center;
  }
  nav .nav-logo {
    position: static;
    display: block;
    margin: 0 auto 0.5em auto;
    top: auto;
    right: auto;
    transform: none;
  }
  nav .nav-links {
    display: block;
  }
}
