html, body {
  height: 100%;
  margin: 0;
  padding: 0;
}

.page-wrapper {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

main.container {
  flex: 1; /* fills vertical space between header and footer */
}

body {
  font-family: 'Inter', sans-serif;
  background: linear-gradient(to bottom, #f0fdf4, #ffffff);
  color: #1f2937;
  display: flex;
  flex-direction: column;
  background-attachment: fixed;
}

/* === HEADER === */
header {
  position: fixed;
  top: 0;
  width: 100%;
  background: #ffffffdd;
  backdrop-filter: blur(8px);
  border-bottom: 1px solid #d1fae5;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
  z-index: 1000;
}

nav {
  max-width: 1200px;
  margin: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem;
}

nav .logo {
  display: flex;
  align-items: center;
}

nav .logo img {
  height: 40px;
  margin-right: 0.75rem;
}

nav .logo span {
  font-weight: 700;
  font-size: 1.1rem;
  color: #166534;
}

nav a {
  margin: 0 0.5rem;
  text-decoration: none;
  color: #1f2937;
  font-weight: 500;
  padding: 0.5rem 0.75rem;
  border-radius: 6px;
  transition: all 0.2s ease-in-out;
  cursor: pointer;
}

nav a:hover {
  background-color: #d1fae5;
  color: #166534;
}

/* === MAIN === */
main.container {
  max-width: 900px;
  margin: 120px auto 40px;
  padding: 0 20px;
  flex: 1;
}

/* === FOOTER === */
footer {
  text-align: center;
  padding: 2rem 0;
  background: linear-gradient(to top, #dcfce7, #f0fdf4);
  font-size: 0.9rem;
  color: #4b5563;
  border-top: 1px solid #d1fae5;
}
footer p {
  text-align: center;
}

/* === TYPOGRAPHY === */
h1, h2, h3 {
  margin-bottom: 1rem;
  color: #14532d;
}

p {
  margin-bottom: 1rem;
  line-height: 1.7;
  text-align: justify;
}

ul {
  margin-left: 1rem;
  margin-bottom: 1rem;
  padding-left: 1rem;
  list-style-type: disc;
}

/* === UTILITY === */
.section {
  display: none;
  animation: fadeIn 0.4s ease;
}
.section.active {
  display: block;
}

a {
  color: #15803d;
}
a:hover {
  text-decoration: underline;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

/* === RESPONSIVE === */
@media (max-width: 600px) {
  nav {
    flex-direction: column;
    align-items: flex-start;
  }

  nav div:nth-child(2) {
    display: flex;
    flex-wrap: wrap;
    margin-top: 0.5rem;
  }

  nav a {
    margin: 0.25rem 0.5rem;
  }
}

.align_right {
  text-align: right;  
}