:root {
    --dark-green: #044b25;
    --pale-green: #b2bb5c;
    --orange: #e5871e;
    --grey: #1F1311;
    --cream: #fbfbec;
}
/* Content area */
.content {
    flex: 1;
    padding: 20px;
}
body {
    margin: 0;
    font-family: 'Merriweather', serif;
    background-color: var(--cream);
    color: var(--dark-green);
    display: flex;  
    height: 100vh;
    max-width: 1200px;
}
  a {
    display: block;
  }
  /* 12.09.25 added */  
  a:link {
  text-decoration-color: var(--dark-green);
  color: var(--dark-green);
  }

  a:visited {
  color: var(--dark-green);
  text-decoration-color: var(--pale-green)
  }
  
  a:hover {
  color: orange;
  text-decoration-color: orange;
  }

tip {
    margin: 0;
    font-family: 'Merriweather', serif;
    background-color: var(--pale-green);
    color: var(--dark-green);
    display: flex;  
    height: 100vh;
    max-width: 1200px;
}
h1 {
  color: #044b25;
}

h2 {
  color: #044b25;
  margin-bottom: 8px
}

h3 {
  color: #044b25;
  margin-bottom: 8px
}

h4 {
  color: #044b25;
  text-align: left;
  margin-bottom: 12px
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

/* Mobile menu button */
.mobile-menu-btn {
    display: none;
    position: fixed;
    top: 10px;
    left: 10px;
    background-color: var(--dark-green);
    color: white;
    padding: 8px 12px;
    border-radius: 4px;
    cursor: pointer;
    z-index: 1000;
}

/* Sidebar styles */
.sidebar {
    width: 250px;
    background-color: var(--cream);
    border-right: 1px solid var(--pale-green);
    padding: 20px;
    box-sizing: border-box;
    overflow-y: auto;
    transition: transform 0.3s ease;
}

/* Logo */
.logo {
    text-align: center;
    margin-bottom: 15px;
}
.logo img {
    max-width: 180px;
    height: 100px;
}

/* Sidebar title */
.sidebar h2 {
    margin-top: 0;
    font-size: 1.4em;
    color: var(--dark-green);
    text-align: center;
}

/* Menu section */
.menu-section {
    margin-bottom: 10px;
    border: 1px solid var(--dark-green);
    background-color: var(--pale-green);
}
.menu-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    background-color: var(--pale-green);
    padding: 10px;
    cursor: pointer;
}

.menu-link {
    color: var(--dark-green);
    font-weight: bold;
    text-decoration: none;
    flex: 1;
}

.menu-link:hover {
    color: var(--orange);
}

.menu-toggle {
    cursor: pointer;
    color: var(--dark-green);
    font-weight: bold;
    margin-left: 10px;
    user-select: none;
}

.menu-toggle.open {
    transform: rotate(90deg);
}
.menu-toggle:hover {
    background-color: var(--orange);
    color: white;
}

/* Submenu list */
.submenu {
    list-style: none;
    background-color: var(--cream);
    margin: 0;
    padding-left: 15px;
    max-height: 0;
    overflow: hidden;       /* hide collapsed content */
    transition: max-height 0.3s ease;
}
/* NEW CODE */
.submenu-level-2.open {
  max-height: 1000px; /* or some value large enough to show all nested items */
}
/* NEW CODE */
/* Submenu text */
.submenu li {
    margin: 5px 0;
}

/* Submenu links */
.submenu a {
    text-decoration: none;
    color: var(--dark-green);
    font-size: 0.8em;
    display: inline;
    padding: 5px 0;
}

/* Hover effect */
.submenu a:hover {
    color: var(--orange);
}

/* Active page highlight */
.submenu a.active {
    background-color: var(--orange);
    color: white;
    padding-left: 5px;
    border-radius: 3px;
}

/* =========================
   Sub-submenu styles
   ========================= */
.submenu-level-2 {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 0;            /* hidden by default */
    overflow: hidden;         /* hide collapsed content */
    transition: max-height 0.3s ease; /* smooth slide */
    margin-left: 15px;        /* visual indent inside parent */
}

/* Optional: style for the little arrow toggle */
.submenu-toggle {
    cursor: pointer;
    margin-left: 6px;
    font-size: 0.8em;
    user-select: none;
    transition: transform 0.3s ease;
}

/* Rotate arrow when open */
.submenu-toggle.open {
    transform: rotate(90deg);
}
/* =========================
   Mobile responsiveness
   ========================= */

/* Mobile responsiveness */
@media (max-width: 768px) {
    .mobile-menu-btn {
        display: inline;
    }
    .sidebar {
        position: fixed;
        left: 0;
        top: 0;
        height: 100%;
        transform: translateX(-100%);
        z-index: 999;
    }
    .sidebar.active {
        transform: translateX(0);
    }
}
/* =========================
   Table of Contents
   ========================= */
.toc {
  border: 1px solid #ddd;
  padding: 1em;
  margin: 1.5em 0;
  background: var(--cream);
  border-radius: 6px;
}

.toc h2 {
  font-size: 1.1rem;
  margin-bottom: 0.5em;
}

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

.toc li {
  margin: 0.3em 0;
}

.toc a {
  text-decoration: none;
  color: #0073e6;
}

.toc a:hover {
  text-decoration: underline;
}

/* =========================
   Glossary and definitions
   ========================= */
.glossary {
  color: var(--orange);
  cursor: pointer;
}

#definition-popup {
  position: fixed;
  max-width: 300px;
  padding: 10px;
  background: var(--pale-green);
  border: 1px solid #333;
  box-shadow: 2px 2px 8px rgba(0,0,0,0.3);
  display: none;
  z-index: 1000;
}

#definition-popup.visible {
  display: block;
}
/* =========================
   Tables
   ========================= */
table {
  width: 100%;
  border-collapse: collapse; /* removes double borders */
  margin-bottom: 20px; /* 👈 space after the table */
}

/* Header cells */
th {
  text-align: left;
  padding: 10px;
  background-color: var(--cream); /* subtle header background */
  border-bottom: 2px solid var(--pale-green);
  vertical-align: top;
}

/* Body cells */
td {
  padding: 10px;
  border-bottom: 1px solid #e0e0e0; /* light divider */
  vertical-align: top; /* text aligns to top by default */
}
/* Optional: highlight on hover */
tr:hover td {
  background-color: #fafafa;
}

/* =========================
   Image grid styles
   ========================= */
  .image-grid {
    max-width: 900px;
    margin-left: 0;
    font-family: 'Merriweather', serif;
    text-align: center;
    color: var(--dark-green);
  }

  .grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
  }

  figure {
    margin: 0;
  }


  /* 12.09.25 added */  
  .grid h3 {
    min-height: 2em; /* Ensures consistent height */
  }

  .grid img {
    width: 100%;
    aspect-ratio: 1 / 1; /* Keeps them square */
    object-fit: cover;
    display: block;
    border-radius: 4px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
  }

  img:hover {
    transform: scale(1.03);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
  }

  figcaption {
    margin-top: 0.5rem;
    font-size: 0.9rem;
    color: var(--dark-green);
  }

/* =========================
   info block styles
   ========================= */
     .info-block-l {
    border: 1px solid #ccc;
    padding: 1rem;
    max-width: 700px;
    font-family: 'Merriweather', serif;
    color: var(--dark-green);
  }

  .info-header-l h2 {
    margin-top: 0;
    margin-bottom: 0rem;
  }

  .info-content-l {
    display: flex;
    gap: 1rem;
    align-items: center;
  }

  .info-image-l {
    max-width: 300px;
    height: auto;
    flex-shrink: 0;
    margin-top: 16px;
    margin-right: 16px;
    margin-bottom: 16px
  }

  .info-text-l {
    flex: 1;
    }
/* =========================
   Multiblock expand
   ========================= */
   details { 
    border: 1px solid var(--border); 
    border-radius: 12px; 
    padding: 0; 
    background: #fbfbec; }

  details + details { margin-top: 14px; }

  summary { 
    cursor: pointer; 
    list-style: none; 
   font-weight: 700; }

  summary::-webkit-details-marker { 
  display: none; }

  summary::marker {
  content: ""; /* For Firefox */
}

    
    /* chevron */
    summary::after {
      content: "🌶️";
      display: inline-block;
      transition: transform .2s ease;
    }

    details[open] > summary::after { 
      transform: rotate(90deg); }

    .section { 
      padding-top: 0px; 
      padding-left: 16px; }
    .subgroup { margin-top: 12px; padding-left: 0; }
    .subgroup details { margin-top: 10px; }
    .text-block { margin: 8px 0; color: #044b25; }

 summary h2 {
  display: inline;
  margin: 0;
  font-size: inherit; /* optional */
}
    summary h3 {
  display: inline;
  margin: 0;
  font-size: inherit; /* optional */
}

/* =========================
   Thumbnail with text block
   ========================= */
  .thumbnail-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.thumbnail-block {
  width: 100%;
  max-width: 800px;
  margin: 0 auto;
  padding: 10px;
  transition: background-color 0.3s ease;
}

.thumbnail-block:hover {
  background-color: (var(--cream));
}

.title {
  text-align: left;
  margin-bottom: 10px;
}

.thumbnail-text {
  display: flex;
  align-items: center;
  gap: 20px;
}

.thumbnail-image {
  width: 100px;
  height: auto;
  transition: transform 0.3s ease;
}

.thumbnail:hover {
  transform: scale(1.05);
}

.text-block {
  flex: 1;
}

/* Mobile-friendly adjustments */
@media (max-width: 600px) {
  .thumbnail-text {
    flex-direction: column;
    align-items: flex-start;
  }

  .thumbnail {
    width: 100%;
    max-width: 300px;
  }

  .text-block {
    width: 100%;
    text-align: left;
  }
}

/* =========================
   Footer styles
   ========================= */

/* Page layout */
.page-wrapper {
  display: grid;
  grid-template-columns: 250px 1fr; /* sidebar + content */
  min-height: calc(100vh - 80px); /* leave space for footer */
}

/* Footer */
.site-footer {
  background-color: var(--cream);
  color:var(--dark-green);
  padding: 0px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1000px;
}

.site-footer img {
  height: 100px;
}

.footer-center {
  text-align: center;
  flex: 1;
}

.footer-center p {
  margin: 0;
}

.footer-center nav a {
  color: #fff;
  margin: 0 10px;
  text-decoration: none;
}

.footer-center nav a:hover {
  text-decoration: underline;
}
