* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    display: flex;
    width: 100%;
    flex-direction: column;
    font-family: "Roboto", sans-serif;
    line-height: 1.6;
    color: #333;
    background: radial-gradient(#5d88fd 30%, rgba(123, 158, 255, 0) 100%);
}
.scroll-to-fixed-fixed {
    transition: top 0.2s ease-in-out;
    -webkit-transition: top 0.2s ease-in-out;
    -moz-transition: top 0.2s ease-in-out;
    -o-transition: top 0.2s ease-in-out;
    z-index: 999999999;
    position: fixed;
}

.nav-container {
    display: flex;
    width: 100%;
    /* transition: top 2000ms; */
    background-color: #2c3e50;
    padding: 1rem;
    justify-content: space-between;
    align-items: center;
    position: fixed;
    top: 0;
    z-index: 1000;
    transition: top 0.3s ease-in-out;
}

.nav-brand {
    padding: 0 1rem;
    color: white;
    text-decoration: none;
    font-size: 1rem;
    font-weight: bold;
}

.nav-brand h1 {
    font-size: 1, 5rem;
}

.nav-menu {
    color: white;
    display: flex;
    align-items: center;
    justify-content: center;
}

.nav-list {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    display: flex;
    position: relative;
    margin: 0 1rem;
}
.nav-item:hover {
    color: #3498db;
}

.nav-link {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.nav-link:hover {
    color: #3498db;
}

/* Dropdown styles */
.dropdown-menu {
    list-style: none;
    position: absolute;
    top: 100%;
    left: 0; /* Cố định vị trí trái */
    background: white;
    color: #000000;
    border-radius: 10px;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    min-width: auto;
    display: none;
    z-index: 1000;
}

.dropdown:hover .dropdown-menu {
    display: block; /* Sửa lại ở đây */
}

.dropdown-menu a {
    display: flex;
    color: #000000;
    padding: 1rem 1rem;
    text-decoration: none;
    align-items: center;
    gap: 0.5rem;
    border-radius: 10px;
    width: 100%; /* Đảm bảo các link chiếm toàn bộ chiều ngang */
}
.dropdown-menu a span {
    white-space: nowrap; /* Không cho phép văn bản ngắt dòng */
}
.dropdown-menu a:hover {
    color: #3498db;
}

/* Auth buttons */
.nav-auth {
    display: flex;

    margin: 0 0.5rem;
    gap: 1rem;
}

.btn-login,
.btn-register,
.btn-logout {
    padding: 0.5rem 1rem;
    border-radius: 10px;
    text-decoration: none;
    font-weight: 500;
    cursor: pointer;
    border: none;
}

.btn-login {
    background: #3498db;
    color: white;
}

.btn-register {
    background: transparent;
    color: white;
    border: 1px solid white;
}

.btn-logout {
    background: #e74c3c;
    color: white;
}

/* Main content */
.main-content {
    /* margin: 1rem auto;*/
    padding: 3rem 1rem 0 1rem; 
}

/* Footer */
.main-footer {
    background: #2c3e50;
    color: white;
    padding: 3rem 1rem;
    margin-top: 3rem;
}

.footer-content {
    display: flex;

    margin: 0 auto;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

.footer-section h3 {
    margin-bottom: 1rem;
    font-size: 1.2rem;
    color: white;
}
.footer-section p {
    color: white;
    padding: 1%;
}

.footer-section a {
    color: white;
    text-decoration: none;
}

.footer-bottom {
    justify-content: center;
    align-items: center;
    text-align: center;
    height: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 15px;
}

/* Responsive design */
.nav-toggle {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0.5rem;
}

.hamburger {
    display: block;
    position: relative;
    width: 24px;
    height: 2px;
    background: white;
}

.hamburger::before,
.hamburger::after {
    content: "";
    position: absolute;
    width: 100%;
    height: 2px;
    background: white;
    left: 0;
}

.hamburger::before {
    top: -6px;
}
.hamburger::after {
    bottom: -6px;
}

@media (max-width: 768px) {
    .nav-toggle {
        display: block;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: #2c3e50;
        padding: 1rem;
    }

    .nav-menu.active {
        display: block;
    }

    .nav-list {
        flex-direction: column;
    }

    .nav-item {
        margin: 0.5rem 0;
    }

    .dropdown-menu {
        position: static;
        box-shadow: none;
        background: transparent;
    }

    .dropdown-menu a {
        color: white;
    }

    .nav-auth {
        margin-top: 1rem;
        flex-direction: column;
    }
}
