/* ✅ Prevent ALL elements from overflowing */
*,
*::before,
*::after {
    box-sizing: border-box;
}

/* ✅ Lock root elements */
html,
body {
    margin: 0;
    padding: 0;
    width: 100%;
    max-width: 100vw;
    overflow-x: hidden;
}

/* DEBUGGING BORDER */
body * {
    outline: none;
    /* Change to 1px dashed red if still debugging */
}

/* General Body Styling */
body {
    font-family: Arial, sans-serif;
    background-color: #f4f4f4;
    color: #333;
}

/* Header */
header {
    background: linear-gradient(90deg, #508D4E, #1A5319);
    padding: 2%;
    text-align: center;
    color: white;
    position: relative;
    width: 100%;
  
}

header h1 {
    margin: 0;
    margin-top: 1%;
}

header p {
    font-size: 1.2em;
}

.auth-section {
    font-size: 1.0em;
    text-align: right;
    color: rgb(255, 251, 216);
    margin-right: 10%;
}

.auth-section a {
    color: white;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 12px;
    transition: color 0.3s ease-in-out, background-color 0.3s ease-in-out;
}

.auth-section a:hover {
    color: #1A5319 !important;
    background-color: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    padding: 8px 12px;
}

/* Banner Section */
.container-banner {
    width: 100%;
    height: 500px;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(rgba(0, 0, 0, 0.5), rgba(0, 0, 0, 0.5));
    position: relative;
    transition: transform 0.5s ease-in-out;
}

.container-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    filter: brightness(80%);
}

.container-banner:hover img {
    transform: scale(1.05);
}

/* Main Container */
.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

/* General Image Styling */
img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Sections */
.section {
    background-color: #fff;
    padding: 5%;
    margin: 20px auto;
    border-radius: 8px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    max-width: 100%;
}

.section h2 {
    color: #1A5319;
    font-size: 1.7em;
}

.section h3 {
    color: white;
    font-size: 1.7em;
}

.section p,
.section li {
    font-size: 1.2em;
    line-height: 1.6;
}

/* Cards Layout */
.card {
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
    margin-top: 10px;
}

.card div {
    background-color: #508D4E;
    color: white;
    padding: 2rem;
    border-radius: 8px;
    flex: 1 1 30%;
    text-align: center;
    cursor: pointer;
    transition: background 0.3s;
    min-width: 200px;
}

.card div:hover {
    background: #1A5319;
}

/* Footer */
footer {
    background: linear-gradient(90deg, #508D4E, #1A5319);
    padding: 2%;
    text-align: center;
    width: 100%;
    color: white;
    position: relative;
    bottom: 0;
}

/* Dropdown container */
.dropdown {
    display: inline-block;
    position: relative;
}

.dropbtn {
    color: white;
    text-decoration: none;
    font-weight: bold;
    padding: 8px 12px;
    transition: color 0.3s ease-in-out, background-color 0.3s ease-in-out;
}

.dropbtn:hover {
    color: #ffff00 !important;
    background-color: rgba(255, 255, 255, 0.91);
    border-radius: 5px;
}

.dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background-color: #333;
    min-width: 100px;
    z-index: 1;
    border-radius: 5px;
}

.dropdown-content a {
    color: white;
    padding: 10px 16px;
    display: block;
    text-align: left;
    text-decoration: none;
}

.dropdown-content a:hover {
    background-color: #444;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* ✅ Responsive Tweaks */
@media (max-width: 768px) {

    .container-banner {
        height: 200px;
    }

    .card {
        flex-direction: column;
        gap: 15px;
    }

    .card div {
        flex: 1 1 100%;
        min-width: unset;
    }

    .section h2,
    .section h3 {
        font-size: 1.4em;
    }

    .section p,
    .section li {
        font-size: 1em;
    }

    .dropdown-content {
        right: 0;
        min-width: 140px;
    }
}

@media (max-width: 480px) {
    header {
        padding: 5%;
    }
    header h1 {
        font-size: 1.2em;
    }

    header p {
        font-size: 0.9em;
    }

    .card h3 {
        font-size: 1.0em;
    }

    .auth-section {
        font-size: 0.6em; /* Even smaller font size */
        margin-right: 0;
    }

    .section h2 {
        font-size: 1.2em;
    }

    .section p,
    .section li {
        font-size: 0.9em;
    }

    .container {
        padding: 0.3rem;
    }

    footer {
        padding: 1%;
    }

    .card div {
        width: 100%; /* Make card take full width on small screens */
        padding: 5px; /* Reduce padding further */
    }
    
}