:root {
    --base-color: #fff;
    --text-color: #000;
    --primary-color: #007bff;
    --secondary-color: #03bbe9;
    --button-color: #f5a613;
    --light-grey: #f0f0f0b4; 
}

body {
    font-family: Arial, sans-serif;
    margin: 0;
    padding-top: 125px;
    background-color: #f4f4f4;
}

/* Fix the Navbar Section at the Top */
.navbar-fix {
    position: fixed; /* Fixes the entire navbar section */
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000; /* Ensures it stays above all content */
}

/* Navbar */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 20px;
    background: var(--base-color);
    color: var(--text-color);
    flex-wrap: wrap;
    height: 50px;
}

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

.navbar .logo h1 {
    margin: 0;
    font-size: 1.5em;
    color: var(--secondary-color);
    margin-right: 10px;
    text-transform: uppercase;
}

.navbar .logos {
    display: flex;
    align-items: center;
}

.navbar .logos img {
    max-width: 50%;
    height: 30%;
    margin: 5px;
}

.navbar .menu {
    margin-left: auto;
}

.navbar .menu ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
}

.navbar .menu ul li {
    display: inline;
    margin-left: 15px;
}

.navbar .menu ul li a {
    color: var(--text-color);
    text-decoration: none;
    font-size: 1em;
    font-weight: 600;
}

/* Secondary Navbar */
.navbar-secondary {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 5px 20px;
    background: var(--base-color);
    flex-wrap: wrap;
    border-bottom: 1px solid var(--secondary-color);
    height: 40px;
}

.navbar-secondary .menu-left ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
}

.navbar-secondary .menu-left ul li {
    margin-right: 15px;
    position: relative;
}

.navbar-secondary .menu-left ul li a {
    text-decoration: none;
    color: #004080;
    font-weight: bold;
    position: relative;
}

.navbar-secondary .menu-left ul li a::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 2px;
    background: #004080;
    bottom: -5px;
    left: 0;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.navbar-secondary .menu-left ul li a:hover::after {
    transform: scaleX(1);
}

.navbar-secondary .menu-right {
    margin-left: auto;
}

.navbar-secondary .menu-right ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    align-items: center;
}

.navbar-secondary .menu-right ul li {
    display: inline;
    margin-left: 15px;
}

.navbar-secondary .menu-right ul li a {
    text-decoration: none;
    color: #004080;
    font-weight: bold;
    font-size: 12px;
}

.navbar .menu ul li a img[src*="ethiopia-flag-icon.svg"] {
    width: 18px; /* Adjust flag size */
    height: auto;
    margin-left: 5px;
}

.navbar .menu ul li a img[src*="sudan-flag-icon.svg"] {
    width: 18px; /* Adjust flag size */
    height: auto;
    margin-left: 5px;
}

.navbar .menu ul li a img[src*="somalia-flag-icon.svg"] {
    width: 18px; /* Adjust flag size */
    height: auto;
    margin-left: 5px;
}

/* Hide the menu toggle on large screens */
.menu-toggle {
    display: none;
    font-size: 24px;
    cursor: pointer;
    padding: 10px;
}

hr {
    margin: 0;
}

/* Main Content Layout */
.container {
    display: flex;
    flex-wrap: wrap;
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
    background: white;
    box-shadow: 0px 0px 10px rgba(0, 0, 0, 0.1);
    border-radius: 5px;
}

/* Two-Column Section */
.two-column {
    display: flex;
    flex-wrap: wrap;
    width: 100%;
}

.left-column, .right-column {
    flex: 1;
    padding: 20px;
    min-width: 300px; /* Ensures proper wrapping on smaller screens */
}

/* Content Box Styling */
.content-box {
    background: white;
    padding: 15px;
    margin-bottom: 15px;
    border-radius: 5px;
    box-shadow: 0px 2px 5px rgba(0, 0, 0, 0.2);
}

/* Inner Border (Only around h3 + ul) */
.inner-border {
    border: 2px solid #ddd;
    padding: 15px;
    border-radius: 8px;
    width: 90%;
}

/* Contents Heading */
.inner-border h3 {
    font-size: 16px;
    color: #333;
    margin-bottom: 15px;
}

/* Links */
.inner-border ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.inner-border ul li {
    margin: 10px 0;
}

.inner-border ul li a {
    text-decoration: none;
    font-size: 14px;
    color: #007bff;
    transition: color 0.3s ease-in-out;
}

.inner-border ul li a:hover {
    color: #0056b3;
}

/* Hide full text initially */
.full-text.hidden {
    display: none;
}

/* 4-Column Grid Layout */
.grid-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr); /* 4 equal columns */
    gap: 20px; /* Adjusted gap for better spacing */
    width: 100%;
    padding: 20px;
}

.grid-container h2 {
    font-size: large;
}
/* Grid Item Styles */
.grid-item {
    background: white;
    padding: 15px;
    border-radius: 8px; /* Smooth rounded edges */
    text-align: left; /* Align text to the left */
    display: flex;
    flex-direction: column;
    align-items: center; /* Keeps image centered */
    justify-content: space-between;
    min-height: 390px; /* Increased height for better balance */
    border: 2px solid #ddd; /* Light gray outline */
    box-shadow: 2px 2px 5px rgba(0, 0, 0, 0.1); /* Subtle shadow */
    margin: 5px; /* Even spacing */
}

/* Align <h4> text to the left */
.grid-item h4 {
    text-align: left; /* Ensures title text is left-aligned */
    width: 100%; /* Prevents it from shrinking */
    margin-bottom: 10px; /* Adds spacing before the image */
}

/* Center Image Inside Grid Item */
.grid-item img {
    width: 85%; /* Slightly smaller width for a balanced look */
    height: auto; /* Maintains aspect ratio */
    max-height: 370px; /* Prevents images from getting too tall */
    border-radius: 5px;
    object-fit: cover; /* Ensures images fit nicely */
    display: block; /* Removes extra spacing */
    margin: auto; /* Centers image inside grid */
}

/* Add margin-top to extra grid items */
.grid-item:nth-child(n+5) { 
    margin-top: 20px; /* Adds spacing after the first row */
}

/* Unique Grid Container */
.grid-container-g {
    display: grid;
    grid-template-columns: repeat(2, 1fr); /* Two items per row */
    gap: 20px;
    margin-top: 20px;
}

.grid-container-g h2{
    font-size: large;
}


.grid-items {
    text-align: center;
    padding: 15px;
    border: 1px solid #ddd;
    background-color: white;
    border-radius: 8px;
}

.grid-items img {
    width: 100%;
    height: 250px;
    max-width: 550px;
    border-radius: 5px;
}


/* Footer Styling */
.footer {
    background-color: #13b1f0;
    color: white;
    text-align: center;
    padding: 20px;
    margin-top: 20px;
}

.footer a {
    color: white;
    text-decoration: none;
    margin: 0 10px;
    font-weight: bold;
}

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

/* Main Content Layout */
.main-content {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    padding: 20px;
    background-color: #f4f4f4; /* Light background */
}

.text-content {
    width: 100%;
    max-width: 1200px; /* Limits content width for better readability */
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
}

/* Table Container */
.content-container {
    overflow-x: auto; /* Ensures responsiveness */
    padding: 10px;
}

/* Table Styling */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    background: white;
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0px 2px 10px rgba(0, 0, 0, 0.1);
}

/* Table Header */
table th {
    background-color: #13b1f0;
    color: white;
    font-weight: bold;
    padding: 12px;
    text-align: left;
}

/* Table Rows */
table td {
    padding: 10px;
    border-bottom: 1px solid #ddd;
}

/* Alternating Row Colors */
table tr:nth-child(even) {
    background-color: #f9f9f9;
}

/* Table Hover Effect */
table tr:hover {
    background-color: #f1f1f1;
}
/* Responsive Adjustments */

/* 📌 Large Screens (Above 1200px) */
@media (min-width: 1201px) {
    .grid-container {
        grid-template-columns: repeat(4, 1fr); /* 4 columns for general grid */
    }
    .grid-container-g {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for guidance manual */
    }
}

/* 📌 Medium-Large Screens (1025px - 1200px) */
@media (max-width: 1200px) {
    .container {
        padding: 10px;
    }
    .grid-container {
        grid-template-columns: repeat(3, 1fr); /* 3 columns for larger screens */
    }
    .grid-container-g {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for guidance manual */
    }
}

/* 📌 Tablets (768px - 1024px) */
@media (max-width: 1024px) {
    .grid-container {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for tablets */
    }
    .grid-container-g {
        grid-template-columns: repeat(2, 1fr); /* 2 columns for guidance manual */
    }
}

/* 📌 Mobile Devices (Below 768px) */
@media (max-width: 768px) {
    body{
        padding: 0%;
    }
    .two-column {
        flex-direction: column;
    }
    .grid-container {
        grid-template-columns: repeat(1, 1fr); /* 1 column for mobile */
    }
    .grid-container-g {
        grid-template-columns: repeat(1, 1fr); /* 1 column for guidance manual */
    }

    .text-content {
        padding: 10px;
    }

    table th, table td {
        padding: 8px;
    }
      /* Show the menu toggle button */
  .navbar .menu {
    display: flex;
    justify-content: space-between; /* Flag+logout left, hamburger right */
    align-items: center;
  }

  .navbar .menu ul {
    display: flex;
    gap: 15px;
    list-style: none;
    margin: 0;
    padding: 0;
  }

  .menu-toggle {
    order: 2;
    cursor: pointer;
    font-size: 1.5rem;
  }

  .menu ul {
    order: 1;
    align-items: center;
  }

  .menu ul li a {
    display: flex;
    align-items: center;
    gap: 5px;
    text-decoration: none;
    color: #fff;
  }
}

/* 📌 Small Mobile Devices (Below 480px) */
@media (max-width: 480px) {
    .navbar .menu ul li {
        margin-left: 10px;
    }
    .navbar-secondary .menu-left ul li {
        margin-right: 10px;
    }
    .navbar-secondary .menu-right ul li {
        margin-left: 10px;
    }

     /* Show the menu toggle button */
  .menu-toggle {
    display: block;
  }

  /* Hide the full menu by default */
  .menu ul,
  .menu-left,
  .menu-right {
    display: none;
    flex-direction: row;
    background: #f9f9f9;
    margin-top: 10px;
  }

  /* When active, show them */
  .menu.active ul,
  .menu-left.active,
  .menu-right.active {
    display: flex;
  }

  .menu ul li,
  .menu-left ul li,
  .menu-right ul li {
    margin: 5px 0;
  }
}
