html {
    box-sizing: border-box;
}
*, *:before, *:after {
    box-sizing: inherit; /* Inherit box-sizing from html */
}
img {
    max-width: 100%;
    height: auto;
}

html, body {
    height: 100%; 
    width: 100%;
    margin: 0; 
    padding: 0;
    overflow-x: hidden;
}

body {
    display: flex;
    flex-direction: column; 
    min-height: 100vh;
    background-size: cover;
}

.logo img {
    max-height: 70px;
    width: auto; 
    border-radius: 8px ;
}

header {
    background-image: linear-gradient(to bottom, #4caa39f3 33%, rgba(104, 172, 96, 0.481) 70%, rgba(156, 220, 141, 0.511) 100%);
    width: 100%;
    color: white;
    padding: 5px 15px;
}

/* base.css updates */
header nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    flex-wrap: wrap; /* Allows items to wrap on small screens */
}

.buttons {
    display: flex;
    gap: 7px ;
    flex-direction: row;
}

@media (max-width: 768px) {
    header {
        padding: 0 !important; /* Remove outer header padding */
    }
    header nav {
        display: flex !important;
        justify-content: space-between !important;
        align-items: center !important;
        padding: 5px 10px !important;
        flex-wrap: nowrap !important;
        gap: 0;
    }

    .logo img {
        max-width: 20dvw;
        margin-left: 0 !important;
    }

    .nav-left {
        display:block;
        flex-shrink: 0;
        padding-left: 0%;
        padding: 0;
        margin: 0;
    }

    .nav-right {
        display: flex !important;
        flex-direction: row !important;
        align-items: flex-end !important;
        gap: 11px !important;
        margin-left: auto;
        flex-grow: 0;
    }

    /* Keep buttons and language selector in a single line */
    .nav-top-row { 
        display: flex;
        flex-direction: row;
        align-items: center;
        gap: 8px;
    }

    /* Remove the "Language" text label */
    nav .dropdown label[for="site-language"] {
        display: none !important;
    }

    nav .dropdown select {
        font-size: 12px !important;
        height: 30px !important;
        min-width: 80px !important;
        padding: 2px 5px !important;
    }

    /* Smaller buttons for the inline row */
    .nav-links-user {
        display: flex !important;
        flex-direction: column !important;
        justify-content: space-between !important; /* Spreads items inside this row */
        width: 100%; /* Ensures it spans the space from logo to edge */
        gap: 10px !important;
        list-style: none;
        padding: 0;
        margin: 0;
    }
    .nav-links-user li a {
        padding: 4px 8px !important;
        font-size: 0.75rem !important;
    }
    .buttons {
        display: flex;
        gap: 7px ;
        flex-direction: row;
    }

    .nav-welcome-message {
        display: block !important; /* Force visibility */
        width: 100%;
        text-align: center;
        margin-top: 2px;
        order: 10;
    }
    .nav-welcome-message span {
        font-size: 0.65rem !important;
        padding: 0 !important;
        margin-top: -2px;
        opacity: 0.9;
        display: block;
    }
    .footer-links {
        display: flex !important;
        flex-direction: row !important;
        flex-wrap: nowrap !important; /* Keep strictly in one line */
        justify-content: space-around !important; /* Spread links across width */
        width: 100% !important;
        gap: 5px !important; /* Minimum gap to prevent touching */
        padding:  10px 0;
    }

    .footer-links a {
        font-size: 0.7rem !important;
        margin-right: 0 !important;
        text-align: center;
        flex: 1; /* Allows each link to take up equal space */
        white-space: nowrap;
    }
    nav .dropdown label { display: none !important; }
    
    nav .dropdown select {
        font-size: 12px !important;
        height: 28px !important;
        min-width: 70px !important;
        padding: 0 5px !important;
    }

    .nav-links-user li a {
        padding: 4px 8px !important;
        font-size: 0.75rem !important;
    }
}

header h1 {
    font-size: 3em;
    margin-bottom: 10px;
}

header p {
    font-size: 1.2em;
}

main {
    flex-grow: 1; 
    padding: 20px; 
}

nav {
    display: flex;
    gap: 50px; /* Space between links */
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.nav-left, .nav-right {
    display: flex;
    align-items: center; 
    gap: 15px; 
  
}

nav .dropdown {
    width: 100%;
    justify-content: center; /* Center language selector */
    position: relative;
    display: inline-block;
}

nav .dropdown label[for="site-language"] {
    font-size: 16px; 
    margin-right: 3px;
    color: #333;
}

nav .dropdown select {
    font-size: 14px; 
    width: auto;
    flex-grow: 1;
    min-width: 110px;
    max-width: 200px;
    height: 39px;
    padding: 7px;
}

.nav-links-user {
    list-style-type: none;
    padding: 0;
    margin: 0; 
    display: flex;
    align-items: center; 
    gap: 10px; 
}

.nav-links-user li a {
    display: inline-block; /* Make the link behave like a block element */
    padding: 8px 12px; /* Add padding for button-like appearance */
    background-color: #298844; 
    color: white; /* Text color */
    font-family: Arial, sans-serif;
    text-decoration: none; /* Remove underline */
    border-radius: 8px; /* Rounded corners */
    transition: background-color 0.2s; /* Smooth transition for hover effect */
    white-space: nowrap;
}
.nav-links-user li a:hover {
    background-color: #87cba1; /* Change background on hover */
}

.nav-welcome-message span {
    padding: 8px 12px; 
    color: rgb(2, 14, 2); 
    white-space: nowrap;
    font-family: Arial, sans-serif;
    font-size: large;
}

#site-language-form {
    margin: 0; 
}

select { /*language chooser */
    padding: 7px 7px;
    font-size: 16px;
    border: 1px solid #000000;
    border-radius: 8px;
    cursor: pointer;
    background-color: #9cce93;
    transition: all 0.2s ease;
}


select:hover {
    background-color: #87cb71;
}

select:focus {
    outline: none;
    border-color: #87cba1;
}

footer {
    background-color: #4caa39f3;
    color: rgb(213, 213, 213);
    padding: 15px 20px;
    font-family:'Lucida Sans', 'Lucida Sans Regular', 'Lucida Grande', 'Lucida Sans Unicode', Geneva, Verdana, sans-serif;
    margin-top: auto;
  }
  
  .footer-container {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
    padding: 1px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.2);
   
    flex-direction: row;
    gap: 10px;
    text-align: center;
  }
  .footer-links{
    display: flex;
    gap: 43px; 
    flex-wrap: wrap;
  }
  .footer-links a {
    margin-right: 15px;
    color: white;
    text-decoration: none;
    font-size: 0.95rem;
    transition: color 0.2s ease-in-out;
  }
  
  .footer-links a:hover {
    text-decoration: underline;
    color: #cceccc;
  }
  
  .footer-social a {
    margin-left: auto;
  }
  
  .footer-social img {
    width: 25px;
    height: auto;
    opacity: 0.85;
    transition: opacity 0.1s ease-in-out;
  }
  
  .footer-social img:hover {
    opacity: 1;
  }
  
.footer-bottom {
    text-align: center;
    font-size: 0.85rem;
    margin-top: 1px;
    width: 100%;
}
  
