/* --- Navbar --- */
.navbar {
    padding: 15px 0;
    transition: all 0.4s ease;
    background: transparent;
}

.navbar.scrolled {
    background: rgba(255, 255, 255, 0.95);
    padding: 10px 0;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.05);
    backdrop-filter: blur(10px);
}

/* Navbar Brand Image */
.navbar-brand img {
    height: 100px;
    width: auto;
}

/* ตัวหนังสือสีขาวตอนปกติ */
.nav-link {
    color: #ffffff !important;
    margin-left: 20px;
    font-weight: 400;
    position: relative;
    transition: color 0.4s ease;
}

/* ตัวหนังสือสีดำเมื่อ scroll ลงมา */
.navbar.scrolled .nav-link {
    color: #000000 !important;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-orange);
    transition: all 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

/* lang-switch สีขาวตอนปกติ / ดำเมื่อ scroll */
.lang-switch a {
    color: #ffffff !important;
    transition: color 0.4s ease;
}

.navbar.scrolled .lang-switch a {
    color: #000000 !important;
}

/* --- Mobile Drawer Menu (Slide from Right) --- */
@media (max-width: 991.98px) {
    .navbar-collapse {
        position: fixed;
        top: 0;
        right: -100%;
        /* ซ่อนอยู่ทางขวา */
        left: auto;
        width: 280px;
        height: 100vh;
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        box-shadow: -5px 0 30px rgba(0, 0, 0, 0.15);
        padding: 80px 30px 30px;
        transition: right 0.4s cubic-bezier(0.77, 0, 0.175, 1);
        z-index: 9999;
        overflow-y: auto;
    }

    .navbar-collapse.show {
        right: 0;
        /* เลื่อนเข้ามาจากขวา */
    }

    .navbar-overlay {
        display: none;
        position: fixed;
        top: 0;
        left: 0;
        width: 100%;
        height: 100%;
        background: rgba(0, 0, 0, 0.5);
        z-index: 9998;
        opacity: 0;
        transition: opacity 0.4s ease;
    }

    .navbar-overlay.active {
        display: block;
        opacity: 1;
    }

    .navbar-collapse .nav-link {
        color: var(--dark-text) !important;
        display: block;
        padding: 14px 0;
        font-size: 1.05rem;
        border-bottom: 1px solid rgba(0, 0, 0, 0.07);
        margin-left: 0;
    }

    .navbar-close-btn {
        display: flex !important;
        position: absolute;
        top: 20px;
        right: 20px;
        background: none;
        border: none;
        font-size: 1.5rem;
        cursor: pointer;
        color: var(--dark-text);
        line-height: 1;
        padding: 5px;
    }

    .lang-switch {
        margin-top: 10px;
        margin-left: 0 !important;
    }

    .lang-switch a {
        color: #000000 !important;
    }
}

.navbar-close-btn {
    display: none;
}

.fixed-top {
    position: fixed;
    top: 0;
    right: 0;
    left: 0;
    z-index: 9999;
}