@import url('https://fonts.googleapis.com/css?family=Poppins:400,500,600,700&display=swap');

* {
    margin: 0;
    padding: 0;
    user-select: none;
    box-sizing: border-box;
    font-family: 'Poppins', sans-serif;
}

body {
    background: #f2f2f2;
}

nav {
    position: relative;
    background: rgb(27, 27, 27);
    transition: background-color 0.3s ease;
    width: 100%;
}

nav:after {
    content: '';
    clear: both;
    display: table;
}

nav .logo {
    float: left;
    color: white;
    font-size: 27px;
    font-weight: 600;
    line-height: 70px;
    padding-left: 60px;
    transition: color 0.3s ease;
}

nav ul {
    float: right;
    margin-right: 40px;
    list-style: none;
    position: relative;
}

nav ul li {
    float: left;
   
    background: rgb(27, 27, 27);
    margin: 0 5px;
    transition: background-color 0.3s ease;
}

nav ul li a {
    color: white;
    line-height: 70px;
    text-decoration: none;
    font-size: 18px;
    padding: 8px 15px;
    transition: color 0.3s ease, background-color 0.3s ease;
}

nav ul li a:hover {
    color: #33ffbb;
    border-radius: 5px;
    box-shadow: 0 0 5px #33ffbb, 0 0 10px #33ffbb;
}

nav ul ul li a:hover {
    box-shadow: none;
}

nav ul ul {
    position: absolute;
    top: 90px;
    border-top: 3px solid #33ffbb;
    opacity: 0;
    visibility: hidden;
    transition: top 0.3s ease, opacity 0.3s ease;
}

nav ul li:hover > ul {
    top: 70px;
    opacity: 1;
    visibility: visible;
}

nav ul ul li {
    position: relative;
    margin: 0px;
    width: 150px;
    float: none;
    display: list-item;
    border-bottom: 1px solid rgba(0, 0, 0, 0.3);
}

nav ul ul li a {
    line-height: 50px;
}

.show, .icon {
    display: none;
}

.fa-plus {
    font-size: 15px;
    margin-left: 40px;
}

@media all and (max-width: 968px) {
    nav ul {
        margin-right: 0px;
        float: left;
    }

    nav .logo {
        padding-left: 30px;
        width: 100%;
    }

    .show + a, ul {
        display: none;
    }

    nav ul li, nav ul ul li {
        display: block;
        width: 100%;
    }

    nav ul li a:hover {
        box-shadow: none;
    }

    .show {
        display: block;
        color: white;
        font-size: 18px;
        padding: 0 20px;
        line-height: 70px;
        cursor: pointer;
    }

    .show:hover {
        color: #33ffbb;
    }

    .icon {
        display: block;
        color: white;
        position: absolute;
        top: 0;
        right: 40px;
        line-height: 70px;
        cursor: pointer;
        font-size: 25px;
    }

    nav ul ul {
        top: 70px;
        border-top: 0px;
        float: none;
        position: static;
        display: none;
        opacity: 1;
        visibility: visible;
    }

    nav ul ul a {
        padding-left: 40px;
    }

    nav ul ul ul a {
        padding-left: 80px;
    }

    nav ul ul ul li {
        position: static;
    }

    /* Display menu when checkbox is checked */
    [id^=btn]:checked + ul {
        display: block;
    }

    nav ul ul li {
        border-bottom: 0px;
    }

    span.cancel:before {
        content: '\f00d';
    }
    
}

.dropdown {
    position: relative;
    display: inline-block;
}

.dropdown .dropbtn {
    background-color: #ffffff;
    border: none;
    cursor: pointer;
    color: #000000;
    font-family: 'Playfair Display', serif;
    font-size: 1rem;
    font-weight: 700;
    transition: color 0.3s;
}

.dropdown .dropbtn:hover {
    color: #4a79a1;
}

.dropdown .dropdown-content {
    display: none;
    position: absolute;
    background-color: #ffffff;
    min-width: 160px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    z-index: 1;
}

.dropdown .dropdown-content a {
    color: #000000;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    font-family: 'Playfair Display', serif;
    font-weight: 700;
}

.dropdown .dropdown-content a:hover {
    background-color: #f1f1f1;
}

.dropdown:hover .dropdown-content {
    display: block;
}

/* Container Styles */
.container {
    background: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0,0,0,0.1);
    max-width: 600px;
    width: 100%;
    margin: 80px auto 0; /* Adjusted margin-top to account for fixed navbar height */
}

.section {
    margin-bottom: 30px;
}

.section h2 {
    font-size: 40px;
    color: rgb(27, 27, 27);
    font-weight: 500;
    text-align: center;
    margin-bottom: 20px;
}

form {
    display: flex;
    flex-direction: column;
}

label {
    margin-bottom: 5px;
    font-weight: bold;
}

input, select {
    padding: 10px;
    margin-bottom: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
}

button {
    padding: 10px;
    background-color: rgb(27, 27, 27);
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
}

button:hover {
    background-color: #333;
}

.result {
    margin-top: 20px;
}

.carbonResult, .travelResult {
    /* background-color: #e9ecef; */
    padding: 15px;
    border-radius: 4px;
    /* border: 1px solid #ccc; */
}

.carbonResult h2, .travelResult h2 {
    font-size: 18px;
    color: #28a745;
}